Skip to content

require.context() rebuilds on every incremental build #6093

Description

@MagicDuck

Do you want to request a feature or report a bug?
bug

What is the current behavior?
require.context() modules get rebuilt even when modifying unrelated file. See image below. In that instance, only the first file was edited, but it seems to rebuild the require.context()'s for the whole product...
image

If the current behavior is a bug, please provide the steps to reproduce.

add a require.context() to one of your js files.
An example: require.context('my-config', true, /[.]json$/);
(in our case, we use an alias in the first arg, not sure if that matters or not)

What is the expected behavior?
require.context() does not get rebuilt each incremental build, unless necessary.

Please mention other relevant information such as the browser version, Node.js version, webpack version and Operating System.
node v8.9.1, webpack 3.8.1

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions