File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ module . exports = {
2+ webpack : {
3+ configure : {
4+ output : {
5+ filename : 'static/js/[name].js' ,
6+ } ,
7+ optimization : {
8+ runtimeChunk : false ,
9+ splitChunks : {
10+ chunks ( chunk ) {
11+ return false
12+ } ,
13+ } ,
14+ } ,
15+ } ,
16+ } ,
17+ plugins : [
18+ {
19+ plugin : {
20+ overrideWebpackConfig : ( { webpackConfig } ) => {
21+ let mcep
22+ webpackConfig . plugins . some ( ( p ) => {
23+ if ( p . constructor . name === 'MiniCssExtractPlugin' ) {
24+ mcep = p
25+ return true
26+ }
27+ } )
28+ if ( mcep ) {
29+ mcep . options . filename = 'static/css/[name].css'
30+ }
31+
32+ return webpackConfig
33+ } ,
34+ } ,
35+ options : { } ,
36+ } ,
37+ ] ,
38+ }
Original file line number Diff line number Diff line change @@ -10,16 +10,17 @@ stores_build() {
1010
1111 rm -f source_code.zip
1212 rm -f extension.zip
13-
14- react-scripts build
13+
14+ yarn global add @craco/craco
15+ craco build
1516
1617 mkdir -p dist
1718 cp -r build/* dist
1819 echo ' zipping the dist'
1920 cd dist/ && zip -r ../extension.zip * -x " *.DS_Store" && cd ..
2021
2122 echo ' zipping the source code for Firefox'
22- zip -r source_code.zip ' public/' ' script/' ' src' ' LICENCE ' ' package.json' ' yarn.lock' ' README.md' -x " *.DS_Store"
23+ zip -r source_code.zip ' public/' ' script/' ' src' ' LICENSE ' ' package.json' ' yarn.lock' ' README.md' -x " *.DS_Store"
2324}
2425
2526stores_build
You can’t perform that action at this time.
0 commit comments