Skip to content

Conversation

@pieh
Copy link
Contributor

@pieh pieh commented Nov 7, 2022

Description

This is mostly for test purposes where webpack config gets recreated and each time it is recreated we lose "previous state" and act like it's entirely new thing. Hoisting those variables outside of apply() function/method scope allow re-use of those variables in future re-compilations

Related Issues

[ch-57103]

@gatsbot gatsbot bot added the status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer label Nov 7, 2022
@pieh pieh added topic: webpack/babel Webpack or babel topic: core Relates to Gatsby's core (e.g. page loading, reporter, state machine) and removed status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer labels Nov 7, 2022
@pieh pieh merged commit bc7ac84 into master Nov 7, 2022
@pieh pieh deleted the pieh-patch-3 branch November 7, 2022 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic: core Relates to Gatsby's core (e.g. page loading, reporter, state machine) topic: webpack/babel Webpack or babel

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants