File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
packages/react-scripts/config Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -6,14 +6,14 @@ const paths = require('./paths');
6
6
const configFactory = require ( './webpack.config' ) ;
7
7
const nodeExternals = require ( 'webpack-node-externals' ) ;
8
8
9
- const pluginFiles = globby . sync ( [ 'plugins/*/index.js ' ] , { cwd : paths . appSrc } ) ;
9
+ const pluginFiles = globby . sync ( [ 'plugins/*/index.{js,ts} ' ] , { cwd : paths . appSrc } ) ;
10
10
const pluginEntries = pluginFiles . reduce ( ( acc , plugin ) => {
11
- acc [ plugin . replace ( / \. j s $ / , '' ) ] = path . join ( paths . appSrc , plugin ) ;
11
+ acc [ plugin . replace ( / \. ( j s | t s ) $ / , '' ) ] = path . join ( paths . appSrc , plugin ) ;
12
12
return acc ;
13
13
} , { } ) ;
14
- const presetFiles = globby . sync ( [ 'presets/*/index.js ' ] , { cwd : paths . appSrc } ) ;
14
+ const presetFiles = globby . sync ( [ 'presets/*/index.{js,ts} ' ] , { cwd : paths . appSrc } ) ;
15
15
const presetEntries = presetFiles . reduce ( ( acc , preset ) => {
16
- acc [ preset . replace ( / \. j s $ / , '' ) ] = path . join ( paths . appSrc , preset ) ;
16
+ acc [ preset . replace ( / \. ( j s | t s ) $ / , '' ) ] = path . join ( paths . appSrc , preset ) ;
17
17
return acc ;
18
18
} , { } ) ;
19
19
You can’t perform that action at this time.
0 commit comments