Coder Social home page Coder Social logo

Watch Mode about autodll-webpack-plugin HOT 7 CLOSED

asfktz avatar asfktz commented on May 23, 2024
Watch Mode

from autodll-webpack-plugin.

Comments (7)

viankakrisna avatar viankakrisna commented on May 23, 2024

For the watch option, I think it should be an array of resolved paths that we should watch.

{
  watch: [
     path.resolve('package.json'),
     path.resolve('package-lock.json'),
     path.resolve('yarn.lock'),
     path.resolve('node_modules')
     path.resolve('webpack.config.js')
  ]
}

And save hashes of those files and directory in the cache folder. So instead of just comparing JSON, isCacheValid will compare hashes of files, folder, and setting. This would affect the initial build time but will make overall validation more accurate in the next start.

Then, the compiler needs to run in watch mode if watch property is truthy in the setting. I haven't thought through the implementation of this phase, should the main compiler run if the DLL compiler finished compiling?

from autodll-webpack-plugin.

viankakrisna avatar viankakrisna commented on May 23, 2024

btw I've written a similar implementation of this plugin in this CRA PR. It would be nice if we can join the feature.

from autodll-webpack-plugin.

asfktz avatar asfktz commented on May 23, 2024

Hi, @viankakrisna! good to see you here (:
I apologize for the late response, the real world got waaay too busy for me in the last few days.
Bad timing I guess 😅

Thanks for the PRs! I am eager to dive into it. That's my plan for tomorrow.

from autodll-webpack-plugin.

viankakrisna avatar viankakrisna commented on May 23, 2024

No problem! Just ping me if you need anything :)

from autodll-webpack-plugin.

asfktz avatar asfktz commented on May 23, 2024

Oh and one more thing!

Please keep in mind that more than one instance of the plugin can be used.
Like in this case: #2 (comment)

from autodll-webpack-plugin.

viankakrisna avatar viankakrisna commented on May 23, 2024

that's making cleanup trickier, maybe we can set up a counter inside the constructor?

from autodll-webpack-plugin.

viankakrisna avatar viankakrisna commented on May 23, 2024

updated #13 with NODE_ENV and instance id

from autodll-webpack-plugin.

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.