-
Notifications
You must be signed in to change notification settings - Fork 12
webpack 4 to 5 #417
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
webpack 4 to 5 #417
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
ccd2546
webpack 4 to 5
breville f90cf97
Fix localhost mode
breville 4a3575c
Update linting
breville 63ae28b
Fix tests
breville 49631f5
Back to most of previous linter
breville 340afc1
Restore spaces
breville e078811
Remove plugins
breville 9ae8c03
Update messageformat
breville 018aed9
Missed file
breville 2ff5d1a
Fix path
breville 9b95af6
Fix lint
breville 0e53fe9
Rename intermediate variable
breville File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,11 +1,3 @@ | ||
| { | ||
| "presets": ["env", "react" ], | ||
| "plugins": [ | ||
| "add-module-exports", | ||
| "syntax-async-functions", | ||
| "transform-object-rest-spread", | ||
| "transform-class-properties", | ||
| ["transform-regenerator", {"async": true, "asyncGenerators": true}], | ||
| ["transform-es2015-classes", {"loose": true}] | ||
| ] | ||
| "presets": ["@babel/preset-env", "@babel/preset-react"] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,14 @@ | ||
| global.__ml_activities_asset_public_path__ = './assets/'; | ||
|
|
||
| export const setAssetPath = (path) => { | ||
| global.__ml_activities_asset_public_path__ = path; | ||
| global.__desired_webpack_public_path__ = path; | ||
| }; | ||
|
|
||
| // Sync webpack's internal public path (__webpack_require__.p) with the global. | ||
| // This is needed when this bundle is nested inside another webpack bundle (e.g. | ||
| // code-dot-org apps): webpack's automatic script-tag URL detection runs first | ||
| // and sets __webpack_require__.p to the host bundle's path. By overriding it | ||
| // here — before source files evaluate their module-level asset requires — | ||
| // asset/resource URLs (sounds, model.json) resolve to the correct location. | ||
| // Fall back to '/' for running locally. | ||
|
|
||
| /* eslint-disable-next-line no-undef */ | ||
| __webpack_public_path__ = global.__desired_webpack_public_path__ || '/'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This fixes the following error when running
yarnin the main repo with a symlinkedml-activities: