File tree Expand file tree Collapse file tree 1 file changed +16
-7
lines changed Expand file tree Collapse file tree 1 file changed +16
-7
lines changed Original file line number Diff line number Diff line change @@ -40,13 +40,6 @@ const sassLoader = {
4040 } ,
4141}
4242
43- webpackRules . RULE_TS = {
44- test : / \. t s x ? $ / ,
45- use : [
46- 'babel-loader' ,
47- ] ,
48- }
49-
5043const cssLoaderOptions = {
5144 modules : {
5245 namedExport : false ,
@@ -110,6 +103,17 @@ webpackRules.RULE_JS.exclude = BabelLoaderExcludeNodeModulesExcept([
110103 'tributejs' ,
111104] )
112105
106+ // Speedup styleguide build
107+ webpackRules . RULE_TS . use = [
108+ 'babel-loader' ,
109+ {
110+ loader : 'ts-loader' ,
111+ options : {
112+ transpileOnly : true ,
113+ } ,
114+ } ,
115+ ]
116+
113117webpackRules . RULE_RAW_SVG = {
114118 resourceQuery : / r a w / ,
115119 type : 'asset/source' ,
@@ -132,5 +136,10 @@ module.exports = () => {
132136 SCOPE_VERSION ,
133137 } ) )
134138
139+ webpackConfig . resolve . extensionAlias = {
140+ '.js' : [ '.ts' , '.js' ] ,
141+ '.mjs' : [ '.mts' , '.mjs' ] ,
142+ }
143+
135144 return webpackConfig
136145}
You can’t perform that action at this time.
0 commit comments