Coder Social home page Coder Social logo

Comments (3)

TomiHiltunen avatar TomiHiltunen commented on May 24, 2024

Same problem here.

from autodll-webpack-plugin.

coagit avatar coagit commented on May 24, 2024

In order to get around this issue you can put webpack-manifest-plugin as a plugin in the auto dll.
Just use a different name for the dll manifest so it won't overwrite your main manifest file.

...

plugins: [
  new AutoDllPlugin({
    entry: {...},
    plugins: [new WebpackManifestPlugin({fileName: 'dll.manifest.json'})]
  })
]

...

Then you will have two manifest files which can be merged somehow, or used separately.

from autodll-webpack-plugin.

stephencookdev avatar stephencookdev commented on May 24, 2024

You can generate just 1 manifest file by adding a custom generate function

const seed = {};
const generate = (_, files) => files.reduce((_, { name, path }) => {
  // modify the shared seed object, so as to share it between the main and
  // DLL compiler instance
  seed[name] = path;
  return seed;
}),

module.exports = {
  plugins: [
    new WebpackManifestPlugin({
      generate,
      seed
    }),
    new AutoDllPlugin({
      plugins: [new WebpackManifestPlugin({
        generate,
        seed,
        fileName: '_throwaway.json'
      })]
    })
  ]
};

Still a bit hacky 😞 but generates 1 correct manifest file

In theory just doing the shared seed thing should solve the issue, but I'm guessing that something is causing the AutoDllPlugin's WebpackManifestPlugin instance to run first, but then output last (causing the staler manifest file to overwrite the newer file - hence the need for the _throwaway.json file)

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.