File tree Expand file tree Collapse file tree 1 file changed +10
-3
lines changed
packages/synthesis-compiler Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -177,9 +177,16 @@ class DissectHtml {
177177 babelJs ( js ) {
178178 const babelOptions = Babel . getDefaultOptions ( ) ;
179179 // const prod = process.env.NODE_ENV ==='production';
180- const external = this . sourceName . match ( / ( b o w e r _ c o m p o n e n t s | n o d e _ m o d u l e s ) \/ / ) ;
181- const buildFile = this . sourceName === 'imports/ui/build.html' ;
182- return ( ! external && ! buildFile ) ? Babel . compile ( js , babelOptions ) . code : js ;
180+ // const external = this.sourceName.match(/(bower_components|node_modules)\//);
181+ // const buildFile = this.sourceName === 'imports/ui/build.html';
182+ // return (!external && !buildFile) ? Babel.compile(js, babelOptions).code : js;
183+ try {
184+ return Babel . compile ( js , babelOptions ) . code ;
185+ }
186+ catch ( err ) {
187+ console . error ( `Error in ${ this . sourceName } ` ) ;
188+ console . error ( err ) ;
189+ }
183190 }
184191
185192 importableUrl ( url ) {
You can’t perform that action at this time.
0 commit comments