Skip to content

Write to .js instead of .jsonΒ #24

@noahgrant

Description

@noahgrant

I love using this plugin to keep my core chunk from changing anytime any of the child chunks change. However, I feel like there's a gap between easy plug-and-play:

  1. This plugin writes the filenames/hashes to a json file and tells webpack to look for them in the global manifestVariable variable.
  2. Webpack is built and looks for these files/hashes in the global manifestVariable variable.

...but we still have to manually attach the json to the global manifestVariable variable ourselves.

It'd be nice to have an option where instead of printing out the json to a .json file, it prints it out to .js file as:

window.<manifestVariable> = <parsedJSON>;

Then all we would need to do is attach the script tag or inline it. Would that make sense?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions