@embroider/core 3.4.3-unstable.65ea799 → 3.4.3-unstable.8bea275
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/src/app-files.js.map +1 -1
- package/src/asset.d.ts +0 -2
- package/src/describe-exports.js.map +1 -1
- package/src/ember-html.d.ts +0 -2
- package/src/ember-html.js.map +1 -1
- package/src/html-entrypoint.js.map +1 -1
- package/src/html-placeholder.js.map +1 -1
- package/src/messages.js.map +1 -1
- package/src/module-resolver.d.ts +4 -3
- package/src/module-resolver.js +110 -116
- package/src/module-resolver.js.map +1 -1
- package/src/node-resolve.d.ts +26 -0
- package/src/node-resolve.js +105 -0
- package/src/node-resolve.js.map +1 -0
- package/src/options.js.map +1 -1
- package/src/packager.js.map +1 -1
- package/src/portable-babel-config.js.map +1 -1
- package/src/portable-babel-launcher.js.map +1 -1
- package/src/portable.js.map +1 -1
- package/src/resolver-loader.js.map +1 -1
- package/src/to-broccoli-plugin.js.map +1 -1
- package/src/virtual-content.js.map +1 -1
- package/src/wait-for-trees.js.map +1 -1
package/src/module-resolver.js
CHANGED
@@ -15,59 +15,47 @@ const path_1 = require("path");
|
|
15
15
|
const shared_internals_2 = require("@embroider/shared-internals");
|
16
16
|
const debug_1 = __importDefault(require("debug"));
|
17
17
|
const assert_never_1 = __importDefault(require("assert-never"));
|
18
|
-
const resolve_1 = __importDefault(require("resolve"));
|
19
18
|
const reverse_exports_1 = __importDefault(require("@embroider/reverse-exports"));
|
20
19
|
const virtual_content_1 = require("./virtual-content");
|
21
20
|
const typescript_memoize_1 = require("typescript-memoize");
|
22
21
|
const describe_exports_1 = require("./describe-exports");
|
23
22
|
const fs_1 = require("fs");
|
23
|
+
const node_resolve_1 = require("./node-resolve");
|
24
24
|
const debug = (0, debug_1.default)('embroider:resolver');
|
25
|
+
// Using a formatter makes this work lazy so nothing happens when we aren't
|
26
|
+
// logging. It is unfortunate that formatters are a globally mutable config and
|
27
|
+
// you can only use single character names, but oh well.
|
28
|
+
debug_1.default.formatters.p = (s) => {
|
29
|
+
let cwd = process.cwd();
|
30
|
+
if (s.startsWith(cwd)) {
|
31
|
+
return s.slice(cwd.length + 1);
|
32
|
+
}
|
33
|
+
return s;
|
34
|
+
};
|
25
35
|
function logTransition(reason, before, after = before) {
|
26
36
|
if (after.isVirtual) {
|
27
|
-
debug(`
|
37
|
+
debug(`[%s:virtualized] %s because %s\n in %p`, before.debugType, before.specifier, reason, before.fromFile);
|
28
38
|
}
|
29
39
|
else if (before.specifier !== after.specifier) {
|
30
40
|
if (before.fromFile !== after.fromFile) {
|
31
|
-
debug(`aliased and rehomed
|
41
|
+
debug(`[%s:aliased and rehomed] %s to %s\n because %s\n from %p\n to %p`, before.debugType, before.specifier, after.specifier, reason, before.fromFile, after.fromFile);
|
32
42
|
}
|
33
43
|
else {
|
34
|
-
debug(`aliased
|
44
|
+
debug(`[%s:aliased] %s to %s\n because %s`, before.debugType, before.specifier, after.specifier, reason);
|
35
45
|
}
|
36
46
|
}
|
37
47
|
else if (before.fromFile !== after.fromFile) {
|
38
|
-
debug(`rehomed
|
48
|
+
debug(`[%s:rehomed] %s, because %s\n from %p\n to %p`, before.debugType, before.specifier, reason, before.fromFile, after.fromFile);
|
49
|
+
}
|
50
|
+
else if (after.isNotFound) {
|
51
|
+
debug(`[%s:not-found] %s because %s\n in %p`, before.debugType, before.specifier, reason, before.fromFile);
|
39
52
|
}
|
40
53
|
else {
|
41
|
-
debug(`
|
54
|
+
debug(`[%s:unchanged] %s because %s\n in %p`, before.debugType, before.specifier, reason, before.fromFile);
|
42
55
|
}
|
43
56
|
return after;
|
44
57
|
}
|
45
58
|
const compatPattern = /#embroider_compat\/(?<type>[^\/]+)\/(?<rest>.*)/;
|
46
|
-
class NodeModuleRequest {
|
47
|
-
constructor(specifier, fromFile, isVirtual, meta) {
|
48
|
-
this.specifier = specifier;
|
49
|
-
this.fromFile = fromFile;
|
50
|
-
this.isVirtual = isVirtual;
|
51
|
-
this.meta = meta;
|
52
|
-
}
|
53
|
-
alias(specifier) {
|
54
|
-
return new NodeModuleRequest(specifier, this.fromFile, false, this.meta);
|
55
|
-
}
|
56
|
-
rehome(fromFile) {
|
57
|
-
if (this.fromFile === fromFile) {
|
58
|
-
return this;
|
59
|
-
}
|
60
|
-
else {
|
61
|
-
return new NodeModuleRequest(this.specifier, fromFile, false, this.meta);
|
62
|
-
}
|
63
|
-
}
|
64
|
-
virtualize(filename) {
|
65
|
-
return new NodeModuleRequest(filename, this.fromFile, true, this.meta);
|
66
|
-
}
|
67
|
-
withMeta(meta) {
|
68
|
-
return new NodeModuleRequest(this.specifier, this.fromFile, this.isVirtual, meta);
|
69
|
-
}
|
70
|
-
}
|
71
59
|
class Resolver {
|
72
60
|
constructor(options) {
|
73
61
|
this.options = options;
|
@@ -144,10 +132,10 @@ class Resolver {
|
|
144
132
|
if (nextRequest.fromFile === request.fromFile && nextRequest.specifier === request.specifier) {
|
145
133
|
throw new Error('Bug Discovered! New request is not === original request but has the same fromFile and specifier. This will likely create a loop.');
|
146
134
|
}
|
147
|
-
if (nextRequest.isVirtual) {
|
148
|
-
// virtual requests are terminal, there is no more
|
149
|
-
// fallbackResolve around them. The defaultResolve is
|
150
|
-
// to implement them.
|
135
|
+
if (nextRequest.isVirtual || nextRequest.isNotFound) {
|
136
|
+
// virtual and NotFound requests are terminal, there is no more
|
137
|
+
// beforeResolve or fallbackResolve around them. The defaultResolve is
|
138
|
+
// expected to know how to implement them.
|
151
139
|
return yield defaultResolve(nextRequest);
|
152
140
|
}
|
153
141
|
return yield* this.internalResolve(nextRequest, defaultResolve);
|
@@ -156,39 +144,7 @@ class Resolver {
|
|
156
144
|
// top. This is a convenience method for calling resolveSync with the
|
157
145
|
// defaultResolve already configured to be "do the normal node thing".
|
158
146
|
nodeResolve(specifier, fromFile) {
|
159
|
-
|
160
|
-
if (request.isVirtual) {
|
161
|
-
return {
|
162
|
-
type: 'found',
|
163
|
-
result: {
|
164
|
-
type: 'virtual',
|
165
|
-
content: (0, virtual_content_1.virtualContent)(request.specifier, this),
|
166
|
-
filename: request.specifier,
|
167
|
-
},
|
168
|
-
};
|
169
|
-
}
|
170
|
-
try {
|
171
|
-
let filename = resolve_1.default.sync(request.specifier, {
|
172
|
-
basedir: (0, path_1.dirname)(request.fromFile),
|
173
|
-
extensions: this.options.resolvableExtensions,
|
174
|
-
});
|
175
|
-
return { type: 'found', result: { type: 'real', filename } };
|
176
|
-
}
|
177
|
-
catch (err) {
|
178
|
-
if (err.code !== 'MODULE_NOT_FOUND') {
|
179
|
-
throw err;
|
180
|
-
}
|
181
|
-
return { type: 'not_found', err };
|
182
|
-
}
|
183
|
-
});
|
184
|
-
switch (resolution.type) {
|
185
|
-
case 'not_found':
|
186
|
-
return resolution;
|
187
|
-
case 'found':
|
188
|
-
return resolution.result;
|
189
|
-
default:
|
190
|
-
throw (0, assert_never_1.default)(resolution);
|
191
|
-
}
|
147
|
+
return (0, node_resolve_1.nodeResolve)(this, specifier, fromFile);
|
192
148
|
}
|
193
149
|
get packageCache() {
|
194
150
|
return shared_internals_2.RewrittenPackageCache.shared('embroider', this.options.appRoot);
|
@@ -418,10 +374,10 @@ class Resolver {
|
|
418
374
|
parseGlobalPath(path, inEngine) {
|
419
375
|
let parts = path.split('@');
|
420
376
|
if (parts.length > 1 && parts[0].length > 0) {
|
421
|
-
return { packageName: parts[0], memberName: parts[1], from: (0, path_1.resolve)(inEngine.root, '
|
377
|
+
return { packageName: parts[0], memberName: parts[1], from: (0, path_1.resolve)(inEngine.root, 'package.json') };
|
422
378
|
}
|
423
379
|
else {
|
424
|
-
return { packageName: inEngine.packageName, memberName: path, from: (0, path_1.resolve)(inEngine.root, '
|
380
|
+
return { packageName: inEngine.packageName, memberName: path, from: (0, path_1.resolve)(inEngine.root, 'package.json') };
|
425
381
|
}
|
426
382
|
}
|
427
383
|
engineConfig(packageName) {
|
@@ -529,7 +485,7 @@ class Resolver {
|
|
529
485
|
return owningEngine;
|
530
486
|
}
|
531
487
|
handleRewrittenPackages(request) {
|
532
|
-
if (request.isVirtual) {
|
488
|
+
if (request.isVirtual || request.isNotFound) {
|
533
489
|
return request;
|
534
490
|
}
|
535
491
|
let requestingPkg = this.packageCache.ownerOfFile(request.fromFile);
|
@@ -548,10 +504,6 @@ class Resolver {
|
|
548
504
|
targetPkg = this.packageCache.resolve(packageName, requestingPkg);
|
549
505
|
}
|
550
506
|
catch (err) {
|
551
|
-
// this is not the place to report resolution failures. If the thing
|
552
|
-
// doesn't resolve, we're just not interested in redirecting it for
|
553
|
-
// backward-compat, that's all. The rest of the system will take care of
|
554
|
-
// reporting a failure to resolve (or handling it a different way)
|
555
507
|
if (err.code !== 'MODULE_NOT_FOUND') {
|
556
508
|
throw err;
|
557
509
|
}
|
@@ -567,14 +519,26 @@ class Resolver {
|
|
567
519
|
return logTransition('request targets a moved package', request, this.resolveWithinMovedPackage(request, targetPkg));
|
568
520
|
}
|
569
521
|
else if (originalRequestingPkg !== requestingPkg) {
|
570
|
-
|
571
|
-
|
572
|
-
|
522
|
+
if (targetPkg) {
|
523
|
+
// in this case, the requesting package is moved but its destination is
|
524
|
+
// not, so we need to rehome the request back to the original location.
|
525
|
+
return logTransition('outbound request from moved package', request, request
|
526
|
+
// setting meta here because if this fails, we want the fallback
|
527
|
+
// logic to revert our rehome and continue from the *moved* package.
|
528
|
+
.withMeta({ originalFromFile: request.fromFile })
|
529
|
+
.rehome((0, path_1.resolve)(originalRequestingPkg.root, 'package.json')));
|
530
|
+
}
|
531
|
+
else {
|
532
|
+
// requesting package was moved and we failed to find its target. We
|
533
|
+
// can't let that accidentally succeed in the defaultResolve because we
|
534
|
+
// could escape the moved package system.
|
535
|
+
return logTransition('missing outbound request from moved package', request, request.notFound());
|
536
|
+
}
|
573
537
|
}
|
574
538
|
return request;
|
575
539
|
}
|
576
540
|
handleRenaming(request) {
|
577
|
-
if (request.isVirtual) {
|
541
|
+
if (request.isVirtual || request.isNotFound) {
|
578
542
|
return request;
|
579
543
|
}
|
580
544
|
let packageName = (0, shared_internals_1.packageName)(request.specifier);
|
@@ -612,7 +576,10 @@ class Resolver {
|
|
612
576
|
// packages get this help, v2 packages are natively supposed to make their
|
613
577
|
// own modules resolvable, and we want to push them all to do that
|
614
578
|
// correctly.
|
615
|
-
|
579
|
+
// "my-package/foo" -> "./foo"
|
580
|
+
// "my-package" -> "./" (this can't be just "." because node's require.resolve doesn't reliable support that)
|
581
|
+
let selfImportPath = request.specifier === pkg.name ? './' : request.specifier.replace(pkg.name, '.');
|
582
|
+
return logTransition(`v1 self-import`, request, request.alias(selfImportPath).rehome((0, path_1.resolve)(pkg.root, 'package.json')));
|
616
583
|
}
|
617
584
|
return request;
|
618
585
|
}
|
@@ -621,16 +588,17 @@ class Resolver {
|
|
621
588
|
if (pkg.name.startsWith('@')) {
|
622
589
|
levels.push('..');
|
623
590
|
}
|
591
|
+
let originalFromFile = request.fromFile;
|
624
592
|
let newRequest = request.rehome((0, path_1.resolve)(pkg.root, ...levels, 'moved-package-target.js'));
|
625
593
|
if (newRequest === request) {
|
626
594
|
return request;
|
627
595
|
}
|
628
|
-
|
629
|
-
|
630
|
-
});
|
596
|
+
// setting meta because if this fails, we want the fallback to pick up back
|
597
|
+
// in the original requesting package.
|
598
|
+
return newRequest.withMeta({ originalFromFile });
|
631
599
|
}
|
632
600
|
preHandleExternal(request) {
|
633
|
-
if (request.isVirtual) {
|
601
|
+
if (request.isVirtual || request.isNotFound) {
|
634
602
|
return request;
|
635
603
|
}
|
636
604
|
let { specifier, fromFile } = request;
|
@@ -663,7 +631,15 @@ class Resolver {
|
|
663
631
|
// engine
|
664
632
|
let logicalLocation = this.reverseSearchAppTree(pkg, request.fromFile);
|
665
633
|
if (logicalLocation) {
|
666
|
-
return logTransition('beforeResolve: relative import in app-js', request, request
|
634
|
+
return logTransition('beforeResolve: relative import in app-js', request, request
|
635
|
+
.alias('./' + path_1.posix.join((0, path_1.dirname)(logicalLocation.inAppName), request.specifier))
|
636
|
+
// it's important that we're rehoming this to the root of the engine
|
637
|
+
// (which we know really exists), and not to a subdir like
|
638
|
+
// logicalLocation.inAppName (which might not physically exist),
|
639
|
+
// because some environments (including node's require.resolve) will
|
640
|
+
// refuse to do resolution from a notional path that doesn't
|
641
|
+
// physically exist.
|
642
|
+
.rehome((0, path_1.resolve)(logicalLocation.owningEngine.root, 'package.json')));
|
667
643
|
}
|
668
644
|
return request;
|
669
645
|
}
|
@@ -678,11 +654,11 @@ class Resolver {
|
|
678
654
|
if (shared_internals_1.emberVirtualPeerDeps.has(packageName) && !pkg.hasDependency(packageName)) {
|
679
655
|
// addons (whether auto-upgraded or not) may use the app's
|
680
656
|
// emberVirtualPeerDeps, like "@glimmer/component" etc.
|
681
|
-
|
682
|
-
|
657
|
+
let addon = this.locateActiveAddon(packageName);
|
658
|
+
if (!addon) {
|
659
|
+
throw new Error(`${pkg.name} is trying to import the emberVirtualPeerDep "${packageName}", but it seems to be missing`);
|
683
660
|
}
|
684
|
-
|
685
|
-
return logTransition(`emberVirtualPeerDeps in v2 addon`, request, request.rehome(newHome));
|
661
|
+
return logTransition(`emberVirtualPeerDeps`, request, request.rehome(addon.canResolveFromFile));
|
686
662
|
}
|
687
663
|
// if this file is part of an addon's app-js, it's really the logical
|
688
664
|
// package to which it belongs (normally the app) that affects some policy
|
@@ -713,6 +689,22 @@ class Resolver {
|
|
713
689
|
}
|
714
690
|
return request;
|
715
691
|
}
|
692
|
+
locateActiveAddon(packageName) {
|
693
|
+
if (packageName === this.options.modulePrefix) {
|
694
|
+
// the app itself is something that addon's can classically resolve if they know it's name.
|
695
|
+
return {
|
696
|
+
root: this.options.appRoot,
|
697
|
+
canResolveFromFile: (0, path_1.resolve)(this.packageCache.maybeMoved(this.packageCache.get(this.options.appRoot)).root, 'package.json'),
|
698
|
+
};
|
699
|
+
}
|
700
|
+
for (let engine of this.options.engines) {
|
701
|
+
for (let addon of engine.activeAddons) {
|
702
|
+
if (addon.name === packageName) {
|
703
|
+
return addon;
|
704
|
+
}
|
705
|
+
}
|
706
|
+
}
|
707
|
+
}
|
716
708
|
external(label, request, specifier) {
|
717
709
|
if (this.options.amdCompatibility === 'cjs') {
|
718
710
|
let filename = (0, virtual_content_1.virtualExternalCJSModule)(specifier);
|
@@ -746,7 +738,7 @@ class Resolver {
|
|
746
738
|
}
|
747
739
|
}
|
748
740
|
fallbackResolve(request) {
|
749
|
-
var _a
|
741
|
+
var _a;
|
750
742
|
if (request.specifier === '@embroider/macros') {
|
751
743
|
// the macros package is always handled directly within babel (not
|
752
744
|
// necessarily as a real resolvable package), so we should not mess with it.
|
@@ -754,8 +746,7 @@ class Resolver {
|
|
754
746
|
// why we need to know about it.
|
755
747
|
return logTransition('fallback early exit', request);
|
756
748
|
}
|
757
|
-
|
758
|
-
if (compatPattern.test(specifier)) {
|
749
|
+
if (compatPattern.test(request.specifier)) {
|
759
750
|
// Some kinds of compat requests get rewritten into other things
|
760
751
|
// deterministically. For example, "#embroider_compat/helpers/whatever"
|
761
752
|
// means only "the-current-engine/helpers/whatever", and if that doesn't
|
@@ -771,39 +762,33 @@ class Resolver {
|
|
771
762
|
// here.
|
772
763
|
return request;
|
773
764
|
}
|
774
|
-
|
775
|
-
if (!((_a = request.meta) === null || _a === void 0 ? void 0 : _a.resolvedWithinPackage)) {
|
776
|
-
throw new Error(`bug: embroider resolver's meta is not propagating`);
|
777
|
-
}
|
778
|
-
fromFile = (0, path_1.resolve)((_b = request.meta) === null || _b === void 0 ? void 0 : _b.resolvedWithinPackage, 'package.json');
|
779
|
-
}
|
780
|
-
let pkg = this.packageCache.ownerOfFile(fromFile);
|
765
|
+
let pkg = this.packageCache.ownerOfFile(request.fromFile);
|
781
766
|
if (!pkg) {
|
782
767
|
return logTransition('no identifiable owningPackage', request);
|
783
768
|
}
|
784
|
-
//
|
785
|
-
// to
|
786
|
-
//
|
787
|
-
// isV2Ember()
|
769
|
+
// meta.originalFromFile gets set when we want to try to rehome a request
|
770
|
+
// but then come back to the original location here in the fallback when the
|
771
|
+
// rehomed request fails
|
788
772
|
let movedPkg = this.packageCache.maybeMoved(pkg);
|
789
773
|
if (movedPkg !== pkg) {
|
790
|
-
|
774
|
+
let originalFromFile = (_a = request.meta) === null || _a === void 0 ? void 0 : _a.originalFromFile;
|
775
|
+
if (typeof originalFromFile !== 'string') {
|
791
776
|
throw new Error(`bug: embroider resolver's meta is not propagating`);
|
792
777
|
}
|
793
|
-
|
778
|
+
request = request.rehome(originalFromFile);
|
794
779
|
pkg = movedPkg;
|
795
780
|
}
|
796
781
|
if (!pkg.isV2Ember()) {
|
797
782
|
return logTransition('fallbackResolve: not in an ember package', request);
|
798
783
|
}
|
799
|
-
let packageName = (0, shared_internals_1.packageName)(specifier);
|
784
|
+
let packageName = (0, shared_internals_1.packageName)(request.specifier);
|
800
785
|
if (!packageName) {
|
801
786
|
// this is a relative import
|
802
787
|
let withinEngine = this.engineConfig(pkg.name);
|
803
788
|
if (withinEngine) {
|
804
789
|
// it's a relative import inside an engine (which also means app), which
|
805
790
|
// means we may need to satisfy the request via app tree merging.
|
806
|
-
let appJSMatch = this.searchAppTree(request, withinEngine, (0, shared_internals_2.explicitRelative)(pkg.root, (0, path_1.resolve)((0, path_1.dirname)(fromFile), specifier)));
|
791
|
+
let appJSMatch = this.searchAppTree(request, withinEngine, (0, shared_internals_2.explicitRelative)(pkg.root, (0, path_1.resolve)((0, path_1.dirname)(request.fromFile), request.specifier)));
|
807
792
|
if (appJSMatch) {
|
808
793
|
return logTransition('fallbackResolve: relative appJsMatch', request, appJSMatch);
|
809
794
|
}
|
@@ -817,23 +802,32 @@ class Resolver {
|
|
817
802
|
}
|
818
803
|
}
|
819
804
|
// auto-upgraded packages can fall back to the set of known active addons
|
820
|
-
if (pkg.meta['auto-upgraded']
|
821
|
-
|
822
|
-
if (
|
823
|
-
|
805
|
+
if (pkg.meta['auto-upgraded']) {
|
806
|
+
let addon = this.locateActiveAddon(packageName);
|
807
|
+
if (addon) {
|
808
|
+
const rehomed = request.rehome(addon.canResolveFromFile);
|
809
|
+
if (rehomed !== request) {
|
810
|
+
return logTransition(`activeAddons`, request, rehomed);
|
811
|
+
}
|
824
812
|
}
|
825
813
|
}
|
826
|
-
let logicalLocation = this.reverseSearchAppTree(pkg, fromFile);
|
814
|
+
let logicalLocation = this.reverseSearchAppTree(pkg, request.fromFile);
|
827
815
|
if (logicalLocation) {
|
828
816
|
// the requesting file is in an addon's appTree. We didn't succeed in
|
829
817
|
// resolving this (non-relative) request from inside the actual addon, so
|
830
818
|
// next try to resolve it from the corresponding logical location in the
|
831
819
|
// app.
|
832
|
-
return logTransition('fallbackResolve: retry from logical home of app-js file', request,
|
820
|
+
return logTransition('fallbackResolve: retry from logical home of app-js file', request,
|
821
|
+
// it might look more precise to rehome into logicalLocation.inAppName
|
822
|
+
// rather than package.json. But that logical location may not actually
|
823
|
+
// exist, and some systems (including node's require.resolve) will be
|
824
|
+
// mad about trying to resolve from notional paths that don't really
|
825
|
+
// exist.
|
826
|
+
request.rehome((0, path_1.resolve)(logicalLocation.owningEngine.root, 'package.json')));
|
833
827
|
}
|
834
828
|
let targetingEngine = this.engineConfig(packageName);
|
835
829
|
if (targetingEngine) {
|
836
|
-
let appJSMatch = this.searchAppTree(request, targetingEngine, specifier.replace(packageName, '.'));
|
830
|
+
let appJSMatch = this.searchAppTree(request, targetingEngine, request.specifier.replace(packageName, '.'));
|
837
831
|
if (appJSMatch) {
|
838
832
|
return logTransition('fallbackResolve: non-relative appJsMatch', request, appJSMatch);
|
839
833
|
}
|
@@ -843,14 +837,14 @@ class Resolver {
|
|
843
837
|
// runtime. Native v2 packages can only get this behavior in the
|
844
838
|
// isExplicitlyExternal case above because they need to explicitly ask for
|
845
839
|
// externals.
|
846
|
-
return this.external('v1 catch-all fallback', request, specifier);
|
840
|
+
return this.external('v1 catch-all fallback', request, request.specifier);
|
847
841
|
}
|
848
842
|
else {
|
849
843
|
// native v2 packages don't automatically externalize *everything* the way
|
850
844
|
// auto-upgraded packages do, but they still externalize known and approved
|
851
845
|
// ember virtual packages (like @ember/component)
|
852
846
|
if (shared_internals_1.emberVirtualPackages.has(packageName)) {
|
853
|
-
return this.external('emberVirtualPackages', request, specifier);
|
847
|
+
return this.external('emberVirtualPackages', request, request.specifier);
|
854
848
|
}
|
855
849
|
}
|
856
850
|
// this is falling through with the original specifier which was
|