Giter Site home page Giter Site logo

Comments (5)

tchaffee avatar tchaffee commented on August 17, 2024

I can take this on, but I'm not sure what has to be done and why and how to test it.

from learn.

Bouncey avatar Bouncey commented on August 17, 2024

So at the minute, in the depths of gatsby-node.js we are using a plugin called CopyWebpackPlugin which copies js/css files that the monaco editor uses into the public dir.

This new plugin I think either does the same job and is supported by the MS Monaco team, of it offers the files up to webpack to include them in the bundle.

Testing would be just running locally and seeing that the editor still works

from learn.

tchaffee avatar tchaffee commented on August 17, 2024

I tried working on this today, but I'm blocked by issue #86.

from learn.

tchaffee avatar tchaffee commented on August 17, 2024

@Bouncey I gave this a shot and am stuck. I keep getting errors where the stack trace points to webpack and properties of compiler.hooks being non-existent. When I dug a little deeper I noticed that monaco-editor-webpack-plugin requires "webpack": "^4.5.0" and gatsbyjs only supports webpack v1. Quite a gap.

One of the problems seems to be around a change to Plugins, which "should use Compiler.hooks.xxx.tap(, fn) now" as of webpack v4. You can read more about the breaking changes for webpack v4 here.

Even v2 of gatsby (still in alpha) only supports webpack v3.

So I'm not sure where to go with this. I think for now the CopyWebpackPlugin is the best solution unless you have other ideas.

from learn.

Bouncey avatar Bouncey commented on August 17, 2024

Oh ok, I didn't know it required webpack v4, thanks for investigating @tchaffee.

Deferring until we hit gatsby v2

from learn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.