Skip to content

Commit

Permalink
4.0.2-next.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Nick Galloway committed Feb 9, 2021
1 parent d50cded commit 0f530f5
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 19 deletions.
28 changes: 14 additions & 14 deletions packages/babel-preset-react-app/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "babel-preset-react-app-webpack-5",
"version": "10.0.0-next.5",
"version": "10.0.0-next.6",
"description": "Babel preset used by Create React App for Webpack 5",
"repository": {
"type": "git",
Expand All @@ -21,19 +21,19 @@
"test.js"
],
"dependencies": {
"@babel/core": "7.12.13",
"@babel/plugin-proposal-class-properties": "7.12.13",
"@babel/plugin-proposal-decorators": "7.12.13",
"@babel/plugin-proposal-nullish-coalescing-operator": "7.12.13",
"@babel/plugin-proposal-numeric-separator": "7.12.13",
"@babel/plugin-proposal-optional-chaining": "7.12.13",
"@babel/plugin-transform-flow-strip-types": "7.12.13",
"@babel/plugin-transform-react-display-name": "7.12.13",
"@babel/plugin-transform-runtime": "7.12.13",
"@babel/preset-env": "7.12.13",
"@babel/preset-react": "7.12.13",
"@babel/preset-typescript": "7.12.13",
"@babel/runtime": "7.12.13",
"@babel/core": "7.12.3",
"@babel/plugin-proposal-class-properties": "7.12.1",
"@babel/plugin-proposal-decorators": "7.12.1",
"@babel/plugin-proposal-nullish-coalescing-operator": "7.12.1",
"@babel/plugin-proposal-numeric-separator": "7.12.1",
"@babel/plugin-proposal-optional-chaining": "7.12.1",
"@babel/plugin-transform-flow-strip-types": "7.12.1",
"@babel/plugin-transform-react-display-name": "7.12.1",
"@babel/plugin-transform-runtime": "7.12.1",
"@babel/preset-env": "7.12.1",
"@babel/preset-react": "7.12.1",
"@babel/preset-typescript": "7.12.1",
"@babel/runtime": "7.12.1",
"babel-plugin-macros": "2.8.0",
"babel-plugin-transform-react-remove-prop-types": "0.4.24"
}
Expand Down
12 changes: 12 additions & 0 deletions packages/react-dev-utils/ModuleScopePlugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,18 @@ class ModuleScopePlugin {
path.dirname(request.context.issuer),
request.__innerRequest_request
);
/* wbpk-5-cra-utils start */
// Fix for @babel/runtime imports
if (
appSrcs.every(appSrc => {
const relative = path.relative(appSrc, requestFullPath);
// If this is an import of a node_module adjacent to our src, allow it
return relative.startsWith('../node_modules') || relative.startsWith('\\node_modules\\');;
})
) {
return callback();
}
/* wbpk-5-cra-utils end */
if (this.allowedFiles.has(requestFullPath)) {
return callback();
}
Expand Down
2 changes: 1 addition & 1 deletion packages/react-dev-utils/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "wbpk-5-cra-utils",
"version": "11.0.2-next.0",
"version": "11.0.2-next.1",
"description": "Webpack 5 utilities used by Create React App",
"repository": {
"type": "git",
Expand Down
5 changes: 4 additions & 1 deletion packages/react-scripts/config/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,10 @@ const safePostCssParser = require('postcss-safe-parser');
const InterpolateHtmlPlugin = require('react-dev-utils/InterpolateHtmlPlugin');
const WorkboxWebpackPlugin = require('workbox-webpack-plugin');
const WatchMissingNodeModulesPlugin = require('react-dev-utils/WatchMissingNodeModulesPlugin');
const ModuleScopePlugin = require('react-dev-utils/ModuleScopePlugin');
/* webpack-5-react-scripts start */
// const ModuleScopePlugin = require('react-dev-utils/ModuleScopePlugin');
const ModuleScopePlugin = require('wbpk-5-cra-utils/ModuleScopePlugin');
/* webpack-5-react-scripts end */
const getCSSModuleLocalIdent = require('react-dev-utils/getCSSModuleLocalIdent');
const ESLintPlugin = require('eslint-webpack-plugin');
const paths = require('./paths');
Expand Down
6 changes: 3 additions & 3 deletions packages/react-scripts/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "webpack-5-react-scripts",
"version": "4.0.2-next.1",
"version": "4.0.2-next.2",
"description": "Configuration and scripts for Create React App using Webpack 5.",
"repository": {
"type": "git",
Expand Down Expand Up @@ -37,7 +37,7 @@
"babel-jest": "^26.6.0",
"babel-loader": "8.1.0",
"babel-plugin-named-asset-import": "^0.3.7",
"babel-preset-react-app-webpack-5": "10.0.0-next.5",
"babel-preset-react-app-webpack-5": "10.0.0-next.6",
"bfj": "^7.0.2",
"camelcase": "^6.1.0",
"case-sensitive-paths-webpack-plugin": "2.3.0",
Expand Down Expand Up @@ -82,7 +82,7 @@
"terser-webpack-plugin": "3.0.1",
"ts-pnp": "1.2.0",
"url-loader": "4.1.1",
"wbpk-5-cra-utils": "11.0.2-next.0",
"wbpk-5-cra-utils": "11.0.2-next.1",
"webpack": "5.10.0",
"webpack-dev-server": "3.11.0",
"webpack-manifest-plugin": "2.2.0",
Expand Down

0 comments on commit 0f530f5

Please sign in to comment.