Skip to content

Commit

Permalink
chore(react-component-tsx): Update kkt dependency to v7
Browse files Browse the repository at this point in the history
Upgrade react-scripts to v5, Support Webpack 5.x
kktjs/kkt#198
  • Loading branch information
jaywcjlove committed Jan 10, 2022
1 parent b8d6a49 commit 06e264b
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 8 deletions.
27 changes: 27 additions & 0 deletions .kktrc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,33 @@ export default (conf: Configuration, env: 'production' | 'development', options:
}));
if (env === 'production') {
conf.output = { ...conf.output, publicPath: './' };
conf.optimization = {
...conf.optimization,
splitChunks: {
cacheGroups: {
reactvendor: {
test: /[\\/]node_modules[\\/](react|react-dom)[\\/]/,
name: 'react-vendor',
chunks: 'all',
},
refractor: {
test: /[\\/]node_modules[\\/](refractor)[\\/]/,
name: 'refractor-prismjs-vendor',
chunks: 'all',
},
runtime: {
test: /[\\/]node_modules[\\/](@babel)[\\/]/,
name: 'babel-vendor',
chunks: 'all',
},
parse5: {
test: /[\\/]node_modules[\\/](parse5)[\\/]/,
name: 'parse5-vendor',
chunks: 'all',
},
}
}
}
}
return conf;
}
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,19 +32,19 @@
"src"
],
"devDependencies": {
"@kkt/raw-modules": "6.11.0",
"@kkt/scope-plugin-options": "6.11.0",
"@types/react": "17.0.37",
"@kkt/raw-modules": "7.0.5",
"@kkt/scope-plugin-options": "7.0.5",
"@types/react": "17.0.38",
"@types/react-dom": "17.0.11",
"@uiw/react-color-sketch": "1.0.6",
"@uiw/react-markdown-preview": "3.4.5",
"@uiw/react-color-sketch": "1.0.7",
"@uiw/react-markdown-preview": "3.4.7",
"@uiw/react-shields": "1.1.2",
"@uiw/reset.css": "1.0.5",
"compile-less-cli": "1.8.9",
"kkt": "6.11.0",
"compile-less-cli": "1.8.11",
"kkt": "7.0.5",
"react": "17.0.2",
"react-dom": "17.0.2",
"tsbb": "3.5.2"
"tsbb": "3.5.4"
},
"eslintConfig": {
"extends": [
Expand Down

0 comments on commit 06e264b

Please sign in to comment.