@@ -383,6 +383,8 @@ function fixRelativeFromPath(fromPath, realSrcPath, realParentPath, externalModu
383
383
}
384
384
}
385
385
386
+ const templateStringRegex = / \$ { .+ } / ;
387
+
386
388
/**
387
389
* Generates key-value dependency pairs of:
388
390
* - <require from="paths">
@@ -402,6 +404,7 @@ function resolveTemplateResources(htmlFilePath, srcPath, externalModule) {
402
404
const requireTags = $ ( 'require' ) ;
403
405
requireTags . each ( index => {
404
406
const fromPath = requireTags [ index ] . attribs . from ;
407
+ if ( templateStringRegex . test ( fromPath ) ) return ;
405
408
const isLazy = requireTags [ index ] . attribs . hasOwnProperty ( 'lazy' ) ;
406
409
const bundle = requireTags [ index ] . attribs . bundle ;
407
410
if ( fromPath )
@@ -412,6 +415,7 @@ function resolveTemplateResources(htmlFilePath, srcPath, externalModule) {
412
415
const viewModelRequests = $ ( '[view-model]' ) ;
413
416
viewModelRequests . each ( index => {
414
417
const fromPath = viewModelRequests [ index ] . attribs [ 'view-model' ] ;
418
+ if ( templateStringRegex . test ( fromPath ) ) return ;
415
419
const isLazy = viewModelRequests [ index ] . attribs . hasOwnProperty ( 'lazy' ) ;
416
420
const bundle = viewModelRequests [ index ] . attribs . bundle ;
417
421
if ( fromPath )
@@ -422,6 +426,7 @@ function resolveTemplateResources(htmlFilePath, srcPath, externalModule) {
422
426
const viewRequests = $ ( '[view]' ) ;
423
427
viewRequests . each ( index => {
424
428
const fromPath = viewRequests [ index ] . attribs . view ;
429
+ if ( templateStringRegex . test ( fromPath ) ) return ;
425
430
const isLazy = viewRequests [ index ] . attribs . hasOwnProperty ( 'lazy' ) ;
426
431
const bundle = viewRequests [ index ] . attribs . bundle ;
427
432
if ( fromPath )
0 commit comments