mirror of
https://github.com/billsonnn/nitro-react.git
synced 2024-11-26 15:40:51 +01:00
Fix dumb dev mode issue
This commit is contained in:
parent
0d5ad1bc97
commit
6b4a9e36e6
@ -5,25 +5,6 @@ module.exports = {
|
||||
webpack: {
|
||||
configure: (webpackConfig) => ({
|
||||
...webpackConfig,
|
||||
module: {
|
||||
...webpackConfig.module,
|
||||
rules: [
|
||||
...webpackConfig.module.rules
|
||||
].map(rule =>
|
||||
{
|
||||
if(!rule.oneOf) return rule;
|
||||
|
||||
return {
|
||||
...rule,
|
||||
oneOf: rule.oneOf.map((ruleObject) =>
|
||||
{
|
||||
if(!new RegExp(ruleObject.test).test('.ts') || !ruleObject.include) return ruleObject;
|
||||
|
||||
return { ...ruleObject, include: undefined };
|
||||
})
|
||||
};
|
||||
})
|
||||
},
|
||||
optimization: {
|
||||
...webpackConfig.optimization,
|
||||
splitChunks: {
|
||||
@ -40,6 +21,23 @@ module.exports = {
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
module: {
|
||||
...webpackConfig.module,
|
||||
rules: webpackConfig.module.rules.map((rule) =>
|
||||
{
|
||||
if(!rule.oneOf) return rule;
|
||||
|
||||
return {
|
||||
...rule,
|
||||
oneOf: rule.oneOf.map((ruleObject) =>
|
||||
{
|
||||
if(!new RegExp(ruleObject.test).test('.ts') || !ruleObject.include) return ruleObject;
|
||||
|
||||
return { ...ruleObject, include: undefined };
|
||||
})
|
||||
};
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
|
14
package.json
14
package.json
@ -10,10 +10,10 @@
|
||||
"eject": "react-scripts eject"
|
||||
},
|
||||
"dependencies": {
|
||||
"@craco/craco": "^6.4.3",
|
||||
"@fortawesome/fontawesome-svg-core": "^1.2.36",
|
||||
"@fortawesome/free-solid-svg-icons": "^5.15.4",
|
||||
"@fortawesome/react-fontawesome": "^0.1.16",
|
||||
"@craco/craco": "^6.3.0",
|
||||
"@fortawesome/fontawesome-svg-core": "^6.1.0",
|
||||
"@fortawesome/free-solid-svg-icons": "^6.1.0",
|
||||
"@fortawesome/react-fontawesome": "^0.1.17",
|
||||
"@nitrots/nitro-renderer": "^1.1.7",
|
||||
"animate.css": "^4.1.1",
|
||||
"classnames": "^2.3.1",
|
||||
@ -29,6 +29,9 @@
|
||||
"react-youtube": "^7.13.1",
|
||||
"typescript": "^4.3.5"
|
||||
},
|
||||
"resolutions": {
|
||||
"react-error-overlay": "6.0.9"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "^12.20.19",
|
||||
"@types/react": "^17.0.15",
|
||||
@ -36,6 +39,7 @@
|
||||
"@types/react-slider": "^1.3.1",
|
||||
"@types/react-transition-group": "^4.4.2",
|
||||
"@types/react-virtualized": "^9.21.13",
|
||||
"@typescript-eslint/eslint-plugin": "^4.29.1"
|
||||
"@typescript-eslint/eslint-plugin": "^4.29.1",
|
||||
"react-error-overlay": "6.0.9"
|
||||
}
|
||||
}
|
||||
|
45
yarn.lock
45
yarn.lock
@ -1095,7 +1095,7 @@
|
||||
exec-sh "^0.3.2"
|
||||
minimist "^1.2.0"
|
||||
|
||||
"@craco/craco@^6.4.3":
|
||||
"@craco/craco@^6.3.0":
|
||||
version "6.4.3"
|
||||
resolved "https://registry.yarnpkg.com/@craco/craco/-/craco-6.4.3.tgz#784395b6ebab764056550a2860494d24c3abd44e"
|
||||
integrity sha512-RzkXYmNzRCGUyG7mM+IUMM+nvrpSfA34352sPSGQN76UivAmCAht3sI4v5JKgzO05oUK9Zwi6abCKD7iKXI8hQ==
|
||||
@ -1144,31 +1144,26 @@
|
||||
minimatch "^3.0.4"
|
||||
strip-json-comments "^3.1.1"
|
||||
|
||||
"@fortawesome/fontawesome-common-types@^0.2.36":
|
||||
version "0.2.36"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-0.2.36.tgz#b44e52db3b6b20523e0c57ef8c42d315532cb903"
|
||||
integrity sha512-a/7BiSgobHAgBWeN7N0w+lAhInrGxksn13uK7231n2m8EDPE3BMCl9NZLTGrj9ZXfCmC6LM0QLqXidIizVQ6yg==
|
||||
"@fortawesome/fontawesome-common-types@6.1.0":
|
||||
version "6.1.0"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-6.1.0.tgz#5a9468da0e5c2a3ccc161882ef5ffafbd3d4882f"
|
||||
integrity sha512-lFIJ5opxOKG9q88xOsuJJAdRZ+2WRldsZwUR/7MJoOMUMhF/LkHUjwWACIEPTa5Wo6uTDHvGRIX+XutdN7zYxA==
|
||||
|
||||
"@fortawesome/fontawesome-common-types@^0.3.0":
|
||||
version "0.3.0"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-0.3.0.tgz#949995a05c0d8801be7e0a594f775f1dbaa0d893"
|
||||
integrity sha512-CA3MAZBTxVsF6SkfkHXDerkhcQs0QPofy43eFdbWJJkZiq3SfiaH1msOkac59rQaqto5EqWnASboY1dBuKen5w==
|
||||
|
||||
"@fortawesome/fontawesome-svg-core@^1.2.36":
|
||||
version "1.3.0"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-svg-core/-/fontawesome-svg-core-1.3.0.tgz#343fac91fa87daa630d26420bfedfba560f85885"
|
||||
integrity sha512-UIL6crBWhjTNQcONt96ExjUnKt1D68foe3xjEensLDclqQ6YagwCRYVQdrp/hW0ALRp/5Fv/VKw+MqTUWYYvPg==
|
||||
"@fortawesome/fontawesome-svg-core@^6.1.0":
|
||||
version "6.1.0"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-svg-core/-/fontawesome-svg-core-6.1.0.tgz#b78a43df315a6b1568d803ee48a9f1edea0714aa"
|
||||
integrity sha512-racj+/EDnMZN0jcuHePOa+9kdHHOCpCAbBvVRnEi4G4DA5SWQiT/uXJ8WcfVEbLN51vPJjhukP4o+zH0cfYplg==
|
||||
dependencies:
|
||||
"@fortawesome/fontawesome-common-types" "^0.3.0"
|
||||
"@fortawesome/fontawesome-common-types" "6.1.0"
|
||||
|
||||
"@fortawesome/free-solid-svg-icons@^5.15.4":
|
||||
version "5.15.4"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-5.15.4.tgz#2a68f3fc3ddda12e52645654142b9e4e8fbb6cc5"
|
||||
integrity sha512-JLmQfz6tdtwxoihXLg6lT78BorrFyCf59SAwBM6qV/0zXyVeDygJVb3fk+j5Qat+Yvcxp1buLTY5iDh1ZSAQ8w==
|
||||
"@fortawesome/free-solid-svg-icons@^6.1.0":
|
||||
version "6.1.0"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-6.1.0.tgz#1bdc3ce6ddd2336348ba324ac4a72161725b0d95"
|
||||
integrity sha512-OOr0jRHl5d41RzBS3sZh5Z3HmdPjMr43PxxKlYeLtQxFSixPf4sJFVM12/rTepB2m0rVShI0vtjHQmzOTlBaXg==
|
||||
dependencies:
|
||||
"@fortawesome/fontawesome-common-types" "^0.2.36"
|
||||
"@fortawesome/fontawesome-common-types" "6.1.0"
|
||||
|
||||
"@fortawesome/react-fontawesome@^0.1.16":
|
||||
"@fortawesome/react-fontawesome@^0.1.17":
|
||||
version "0.1.17"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/react-fontawesome/-/react-fontawesome-0.1.17.tgz#06fc06cb1a721e38e5b50b4a1cb851e9b9c77d7a"
|
||||
integrity sha512-dX43Z5IvMaW7fwzU8farosYjKNGfRb2HB/DgjVBHeJZ/NSnuuaujPPx0YOdcAq+n3mqn70tyCde2HM1mqbhiuw==
|
||||
@ -9855,10 +9850,10 @@ react-dom@^17.0.2:
|
||||
object-assign "^4.1.1"
|
||||
scheduler "^0.20.2"
|
||||
|
||||
react-error-overlay@^6.0.9:
|
||||
version "6.0.10"
|
||||
resolved "https://registry.yarnpkg.com/react-error-overlay/-/react-error-overlay-6.0.10.tgz#0fe26db4fa85d9dbb8624729580e90e7159a59a6"
|
||||
integrity sha512-mKR90fX7Pm5seCOfz8q9F+66VCc1PGsWSBxKbITjfKVQHMNF2zudxHnMdJiB1fRCb+XsbQV9sO9DCkgsMQgBIA==
|
||||
react-error-overlay@6.0.9, react-error-overlay@^6.0.9:
|
||||
version "6.0.9"
|
||||
resolved "https://registry.yarnpkg.com/react-error-overlay/-/react-error-overlay-6.0.9.tgz#3c743010c9359608c375ecd6bc76f35d93995b0a"
|
||||
integrity sha512-nQTTcUu+ATDbrSD1BZHr5kgSD4oF8OFjxun8uAaL8RwPBacGBNPf/yAuVVdx17N8XNzRDMrZ9XcKZHCjPW+9ew==
|
||||
|
||||
react-is@^16.13.1, react-is@^16.3.2, react-is@^16.8.1:
|
||||
version "16.13.1"
|
||||
|
Loading…
Reference in New Issue
Block a user