@embroider/core 3.4.4 → 3.4.6-unstable.11f2c70

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@embroider/core",
3
- "version": "3.4.4",
3
+ "version": "3.4.6-unstable.11f2c70",
4
4
  "private": false,
5
5
  "description": "A build system for EmberJS applications.",
6
6
  "repository": {
@@ -16,10 +16,15 @@
16
16
  "src/**/*.d.ts",
17
17
  "src/**/*.js.map"
18
18
  ],
19
+ "scripts": {
20
+ "test": "jest"
21
+ },
19
22
  "dependencies": {
20
23
  "@babel/core": "^7.14.5",
21
24
  "@babel/parser": "^7.14.5",
22
25
  "@babel/traverse": "^7.14.5",
26
+ "@embroider/macros": "1.14.1-unstable.11f2c70",
27
+ "@embroider/shared-internals": "2.5.3-unstable.11f2c70",
23
28
  "assert-never": "^1.2.1",
24
29
  "babel-plugin-ember-template-compilation": "^2.1.1",
25
30
  "broccoli-node-api": "^1.7.0",
@@ -37,12 +42,14 @@
37
42
  "lodash": "^4.17.21",
38
43
  "resolve": "^1.20.0",
39
44
  "resolve-package-path": "^4.0.1",
45
+ "resolve.exports": "^2.0.2",
46
+ "@embroider/reverse-exports": "0.1.1-unstable.11f2c70",
40
47
  "typescript-memoize": "^1.0.1",
41
- "walk-sync": "^3.0.0",
42
- "@embroider/macros": "1.13.5",
43
- "@embroider/shared-internals": "2.5.2"
48
+ "walk-sync": "^3.0.0"
44
49
  },
45
50
  "devDependencies": {
51
+ "@embroider/sample-transforms": "workspace:*",
52
+ "@embroider/test-support": "workspace:*",
46
53
  "@glimmer/syntax": "^0.84.2",
47
54
  "@glint/template": "^1.0.0",
48
55
  "@types/babel__core": "^7.1.14",
@@ -57,14 +64,9 @@
57
64
  "@types/tmp": "^0.1.0",
58
65
  "fixturify": "^2.1.1",
59
66
  "tmp": "^0.1.0",
60
- "typescript": "^5.1.6",
61
- "@embroider/test-support": "0.36.0",
62
- "@embroider/sample-transforms": "0.0.0"
67
+ "typescript": "^5.1.6"
63
68
  },
64
69
  "engines": {
65
70
  "node": "12.* || 14.* || >= 16"
66
- },
67
- "scripts": {
68
- "test": "jest"
69
71
  }
70
- }
72
+ }
@@ -27,7 +27,7 @@ export declare class AppFiles {
27
27
  }
28
28
  export interface Engine {
29
29
  package: Package;
30
- addons: Set<AddonPackage>;
30
+ addons: Map<AddonPackage, string>;
31
31
  parent: Engine | undefined;
32
32
  sourcePath: string;
33
33
  modulePrefix: string;
package/src/app-files.js CHANGED
@@ -21,7 +21,7 @@ class AppFiles {
21
21
  for (let f of fastbootFiles) {
22
22
  combinedFiles.add(f);
23
23
  }
24
- for (let addon of engine.addons) {
24
+ for (let addon of engine.addons.keys()) {
25
25
  let appJS = addon.meta['app-js'];
26
26
  if (appJS) {
27
27
  for (let filename of Object.keys(appJS)) {
@@ -1 +1 @@
1
- {"version":3,"file":"app-files.js","sourceRoot":"","sources":["app-files.ts"],"names":[],"mappings":";;;AAAA,+BAA2B;AAU3B,MAAa,QAAQ;IAUnB,YACW,MAAc,EACvB,QAAqB,EACrB,aAA0B,EAC1B,oBAA4B,EAC5B,eAAwB;QAJf,WAAM,GAAN,MAAM,CAAQ;QAMvB,IAAI,KAAK,GAAa,EAAE,CAAC;QACzB,IAAI,UAAU,GAAa,EAAE,CAAC;QAC9B,IAAI,OAAO,GAAa,EAAE,CAAC;QAC3B,IAAI,SAAS,GAAa,EAAE,CAAC;QAC7B,IAAI,aAAa,GAAa,EAAE,CAAC;QACjC,IAAI,CAAC,QAAQ,GAAG,EAAE,QAAQ,EAAE,IAAI,GAAG,EAAE,EAAE,CAAC;QAExC,IAAI,aAAa,GAAG,IAAI,GAAG,EAAU,CAAC;QACtC,IAAI,wBAAwB,GAAG,IAAI,GAAG,EAAU,CAAC;QACjD,IAAI,cAAc,GAAG,IAAI,GAAG,EAAmB,CAAC;QAEhD,KAAK,IAAI,CAAC,IAAI,QAAQ,EAAE;YACtB,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;YACrB,wB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AAC;aACnB;SACF;QACD,MAAM,CAAC,IAA2C,CAAC,GAAG,YAAY,CAAC;QACnE,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,UAAU;QACZ,OAAO,IAAI,CAAC,QAAQ,CAAC;IACvB,CAAC;CACF;AA7LD,4BA6LC","sourcesContent":["import { sep } from 'path';\nimport type { Package, AddonPackage } from '@embroider/shared-internals';\n\nexport interface RouteFiles {\n route?: string;\n template?: string;\n controller?: string;\n children: Map<string, RouteFiles>;\n}\n\nexport class AppFiles {\n readonly tests: ReadonlyArray<string>;\n readonly components: ReadonlyArray<string>;\n readonly helpers: ReadonlyArray<string>;\n readonly modifiers: ReadonlyArray<string>;\n private perRoute: RouteFiles;\n readonly otherAppFiles: ReadonlyArray<string>;\n readonly isFastbootOnly: Map<string, boolean>;\n readonly fastbootFiles: { [appName: string]: { localFilename: string; shadowedFilename: string | undefined } };\n\n constructor(\n readonly engine: Engine,\n appFiles: Set<string>,\n fastbootFiles: Set<string>,\n resolvableExtensions: RegExp,\n podModulePrefix?: string\n ) {\n let tests: string[] = [];\n let components: string[] = [];\n let helpers: string[] = [];\n let modifiers: string[] = [];\n let otherAppFiles: string[] = [];\n this.perRoute = { children: new Map() };\n\n let combinedFiles = new Set<string>();\n let combinedNonFastbootFiles = new Set<string>();\n let isFastbootOnly = new Map<string, boolean>();\n\n for (let f of appFiles) {\n combinedFiles.add(f);\n combinedNonFastbootFiles.add(f);\n }\n for (let f of fastbootFiles) {\n combinedFiles.add(f);\n }\n\n for (let addon of engine.addons) {\n let appJS = addon.meta['app-js'];\n if (appJS) {\n for (let filename of Object.keys(appJS)) {\n filename = filename.replace(/^\\.\\//, '');\n combinedFiles.add(filename);\n combinedNonFastbootFiles.add(filename);\n }\n }\n\n let fastbootJS = addon.meta['fastboot-js'];\n if (fastbootJS) {\n for (let filename of Object.keys(fastbootJS)) {\n filename = filename.replace(/^\\.\\//, '');\n combinedFiles.add(filename);\n }\n }\n }\n\n for (let relativePath of combinedFiles) {\n isFastbootOnly.set(relativePath, !combinedNonFastbootFiles.has(relativePath));\n relativePath = relativePath.split(sep).join('/');\n if (!resolvableExtensions.test(relativePath)) {\n continue;\n }\n\n if (/\\.d\\.ts$/.test(relativePath)) {\n // .d.ts files are technically \"*.ts\" files but aren't really and we\n // don't want to include them when we crawl through the app.\n continue;\n }\n\n if (relativePath.startsWith('tests/')) {\n tests.push(relativePath);\n continue;\n }\n\n if (relativePath.startsWith('components/')) {\n // hbs files are resolvable, but not when they're used via co-location.\n // An hbs file is used via colocation when it's inside the components\n // directory, and also not named \"template.hbs\" (because that is an\n // older pattern used with pods-like layouts).\n if (!relativePath.endsWith('.hbs') || relativePath.endsWith('/template.hbs')) {\n components.push(relativePath);\n }\n continue;\n }\n\n if (relativePath.startsWith('templates/components/')) {\n components.push(relativePath);\n continue;\n }\n\n if (relativePath.startsWith('helpers/')) {\n helpers.push(relativePath);\n continue;\n }\n\n if (relativePath.startsWith('modifiers/')) {\n modifiers.push(relativePath);\n continue;\n }\n\n if (\n (podModulePrefix !== undefined && this.handlePodsRouteFile(relativePath, podModulePrefix)) ||\n this.handleClassicRouteFile(relativePath)\n ) {\n continue;\n }\n\n otherAppFiles.push(relativePath);\n }\n this.tests = tests;\n this.components = components;\n this.helpers = helpers;\n this.modifiers = modifiers;\n this.otherAppFiles = otherAppFiles;\n this.isFastbootOnly = isFastbootOnly;\n\n // this deliberately only describes the app's fastboot files. Not the full\n // merge from all the addons. This is because they need different handling\n // in the module resolver -- addon fastboot files can always be a\n // fallbackResolve, because if the app happens to define the same name\n // (whether fastboot-specific or just browser) that wins over the addon.\n // Whereas if the app itself defines a fastbot-specific version of a file,\n // that must take precedence over the *normal* resolution, and must be\n // implemented in beforeResolve.\n this.fastbootFiles = Object.fromEntries(\n [...fastbootFiles].map(name => [\n `./${name}`,\n {\n localFilename: `./_fastboot_/${name}`,\n shadowedFilename: appFiles.has(name) ? `./${name}` : undefined,\n },\n ])\n );\n }\n\n private handleClassicRouteFile(relativePath: string): boolean {\n let [prefix, ...rest] = relativePath.replace(/\\.\\w{1,3}$/, '').split('/');\n if (!['controllers', 'templates', 'routes'].includes(prefix)) {\n return false;\n }\n let type = prefix.slice(0, -1) as 'controller' | 'template' | 'route';\n let cursor = this.perRoute;\n for (let part of rest) {\n let child = cursor.children.get(part);\n if (child) {\n cursor = child;\n } else {\n let newEntry = { children: new Map() };\n cursor.children.set(part, newEntry);\n cursor = newEntry;\n }\n }\n cursor[type] = relativePath;\n return true;\n }\n\n private handlePodsRouteFile(relativePath: string, podModulePrefix: string): boolean {\n let parts = relativePath.replace(/\\.\\w{1,3}$/, '').split('/');\n let type = parts.pop();\n if (!type || !['controller', 'template', 'route'].includes(type)) {\n return false;\n }\n let podParts = podModulePrefix.split('/');\n // The first part of podModulePrefix is the app's package name\n podParts.shift();\n\n for (let podPart of podParts) {\n if (parts.shift() !== podPart) {\n return false;\n }\n }\n\n let cursor = this.perRoute;\n for (let part of parts) {\n let child = cursor.children.get(part);\n if (child) {\n cursor = child;\n } else {\n let newEntry = { children: new Map() };\n cursor.children.set(part, newEntry);\n cursor = newEntry;\n }\n }\n cursor[type as 'controller' | 'template' | 'route'] = relativePath;\n return true;\n }\n\n get routeFiles(): Readonly<RouteFiles> {\n return this.perRoute;\n }\n}\n\nexport interface Engine {\n // the engine's own package\n package: Package;\n // the set of active addons in the engine\n addons: Set<AddonPackage>;\n // the parent engine, if any\n parent: Engine | undefined;\n // where the engine's own V2 code comes from\n sourcePath: string;\n // runtime name for the engine's own module namespace\n modulePrefix: string;\n // this is destPath but relative to the app itself\n appRelativePath: string;\n}\n"]}
1
+ {"version":3,"file":"app-files.js","sourceRoot":"","sources":["app-files.ts"],"names":[],"mappings":";;;AAAA,+BAA2B;AAU3B,MAAa,QAAQ;IAUnB,YACW,MAAc,EACvB,QAAqB,EACrB,aAA0B,EAC1B,oBAA4B,EAC5B,eAAwB;QAJf,WAAM,GAAN,MAAM,CAAQ;QAMvB,IAAI,KAAK,GAAa,EAAE,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IAAI,KAAK,CAAC,KAAK,EAAE,KAAK,OAAO,EAAE;gBAC7B,OAAO,KAAK,CAAC;aACd;SACF;QAED,IAAI,MAAM,GAAG,IAAI,CAAC,QAAQ,CAAC;QAC3B,KAAK,IAAI,IAAI,IAAI,KAAK,EAAE;YACtB,IAAI,KAAK,GAAG,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;YACtC,IAAI,KAAK,EAAE;gBACT,MAAM,GAAG,KAAK,CAAC;aAChB;iBAAM;gBACL,IAAI,QAAQ,GAAG,EAAE,QAAQ,EAAE,IAAI,GAAG,EAAE,EAAE,CAAC;gBACvC,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;gBACpC,MAAM,GAAG,QAAQ,CAAC;aACnB;SACF;QACD,MAAM,CAAC,IAA2C,CAAC,GAAG,YAAY,CAAC;QACnE,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,UAAU;QACZ,OAAO,IAAI,CAAC,QAAQ,CAAC;IACvB,CAAC;CACF;AA7LD,4BA6LC","sourcesContent":["import { sep } from 'path';\nimport type { Package, AddonPackage } from '@embroider/shared-internals';\n\nexport interface RouteFiles {\n route?: string;\n template?: string;\n controller?: string;\n children: Map<string, RouteFiles>;\n}\n\nexport class AppFiles {\n readonly tests: ReadonlyArray<string>;\n readonly components: ReadonlyArray<string>;\n readonly helpers: ReadonlyArray<string>;\n readonly modifiers: ReadonlyArray<string>;\n private perRoute: RouteFiles;\n readonly otherAppFiles: ReadonlyArray<string>;\n readonly isFastbootOnly: Map<string, boolean>;\n readonly fastbootFiles: { [appName: string]: { localFilename: string; shadowedFilename: string | undefined } };\n\n constructor(\n readonly engine: Engine,\n appFiles: Set<string>,\n fastbootFiles: Set<string>,\n resolvableExtensions: RegExp,\n podModulePrefix?: string\n ) {\n let tests: string[] = [];\n let components: string[] = [];\n let helpers: string[] = [];\n let modifiers: string[] = [];\n let otherAppFiles: string[] = [];\n this.perRoute = { children: new Map() };\n\n let combinedFiles = new Set<string>();\n let combinedNonFastbootFiles = new Set<string>();\n let isFastbootOnly = new Map<string, boolean>();\n\n for (let f of appFiles) {\n combinedFiles.add(f);\n combinedNonFastbootFiles.add(f);\n }\n for (let f of fastbootFiles) {\n combinedFiles.add(f);\n }\n\n for (let addon of engine.addons.keys()) {\n let appJS = addon.meta['app-js'];\n if (appJS) {\n for (let filename of Object.keys(appJS)) {\n filename = filename.replace(/^\\.\\//, '');\n combinedFiles.add(filename);\n combinedNonFastbootFiles.add(filename);\n }\n }\n\n let fastbootJS = addon.meta['fastboot-js'];\n if (fastbootJS) {\n for (let filename of Object.keys(fastbootJS)) {\n filename = filename.replace(/^\\.\\//, '');\n combinedFiles.add(filename);\n }\n }\n }\n\n for (let relativePath of combinedFiles) {\n isFastbootOnly.set(relativePath, !combinedNonFastbootFiles.has(relativePath));\n relativePath = relativePath.split(sep).join('/');\n if (!resolvableExtensions.test(relativePath)) {\n continue;\n }\n\n if (/\\.d\\.ts$/.test(relativePath)) {\n // .d.ts files are technically \"*.ts\" files but aren't really and we\n // don't want to include them when we crawl through the app.\n continue;\n }\n\n if (relativePath.startsWith('tests/')) {\n tests.push(relativePath);\n continue;\n }\n\n if (relativePath.startsWith('components/')) {\n // hbs files are resolvable, but not when they're used via co-location.\n // An hbs file is used via colocation when it's inside the components\n // directory, and also not named \"template.hbs\" (because that is an\n // older pattern used with pods-like layouts).\n if (!relativePath.endsWith('.hbs') || relativePath.endsWith('/template.hbs')) {\n components.push(relativePath);\n }\n continue;\n }\n\n if (relativePath.startsWith('templates/components/')) {\n components.push(relativePath);\n continue;\n }\n\n if (relativePath.startsWith('helpers/')) {\n helpers.push(relativePath);\n continue;\n }\n\n if (relativePath.startsWith('modifiers/')) {\n modifiers.push(relativePath);\n continue;\n }\n\n if (\n (podModulePrefix !== undefined && this.handlePodsRouteFile(relativePath, podModulePrefix)) ||\n this.handleClassicRouteFile(relativePath)\n ) {\n continue;\n }\n\n otherAppFiles.push(relativePath);\n }\n this.tests = tests;\n this.components = components;\n this.helpers = helpers;\n this.modifiers = modifiers;\n this.otherAppFiles = otherAppFiles;\n this.isFastbootOnly = isFastbootOnly;\n\n // this deliberately only describes the app's fastboot files. Not the full\n // merge from all the addons. This is because they need different handling\n // in the module resolver -- addon fastboot files can always be a\n // fallbackResolve, because if the app happens to define the same name\n // (whether fastboot-specific or just browser) that wins over the addon.\n // Whereas if the app itself defines a fastbot-specific version of a file,\n // that must take precedence over the *normal* resolution, and must be\n // implemented in beforeResolve.\n this.fastbootFiles = Object.fromEntries(\n [...fastbootFiles].map(name => [\n `./${name}`,\n {\n localFilename: `./_fastboot_/${name}`,\n shadowedFilename: appFiles.has(name) ? `./${name}` : undefined,\n },\n ])\n );\n }\n\n private handleClassicRouteFile(relativePath: string): boolean {\n let [prefix, ...rest] = relativePath.replace(/\\.\\w{1,3}$/, '').split('/');\n if (!['controllers', 'templates', 'routes'].includes(prefix)) {\n return false;\n }\n let type = prefix.slice(0, -1) as 'controller' | 'template' | 'route';\n let cursor = this.perRoute;\n for (let part of rest) {\n let child = cursor.children.get(part);\n if (child) {\n cursor = child;\n } else {\n let newEntry = { children: new Map() };\n cursor.children.set(part, newEntry);\n cursor = newEntry;\n }\n }\n cursor[type] = relativePath;\n return true;\n }\n\n private handlePodsRouteFile(relativePath: string, podModulePrefix: string): boolean {\n let parts = relativePath.replace(/\\.\\w{1,3}$/, '').split('/');\n let type = parts.pop();\n if (!type || !['controller', 'template', 'route'].includes(type)) {\n return false;\n }\n let podParts = podModulePrefix.split('/');\n // The first part of podModulePrefix is the app's package name\n podParts.shift();\n\n for (let podPart of podParts) {\n if (parts.shift() !== podPart) {\n return false;\n }\n }\n\n let cursor = this.perRoute;\n for (let part of parts) {\n let child = cursor.children.get(part);\n if (child) {\n cursor = child;\n } else {\n let newEntry = { children: new Map() };\n cursor.children.set(part, newEntry);\n cursor = newEntry;\n }\n }\n cursor[type as 'controller' | 'template' | 'route'] = relativePath;\n return true;\n }\n\n get routeFiles(): Readonly<RouteFiles> {\n return this.perRoute;\n }\n}\n\nexport interface Engine {\n // the engine's own package\n package: Package;\n // the set of active addons in the engine. For each one we keep track of a file that can resolve the addon, because we'll need that later.\n addons: Map<AddonPackage, string>;\n // the parent engine, if any\n parent: Engine | undefined;\n // where the engine's own V2 code comes from\n sourcePath: string;\n // runtime name for the engine's own module namespace\n modulePrefix: string;\n // this is destPath but relative to the app itself\n appRelativePath: string;\n}\n"]}
package/src/index.d.ts CHANGED
@@ -7,7 +7,7 @@ export { default as toBroccoliPlugin } from './to-broccoli-plugin';
7
7
  export { default as WaitForTrees, OutputPaths } from './wait-for-trees';
8
8
  export { compile as jsHandlebarsCompile } from './js-handlebars';
9
9
  export { todo, unsupported, warn, debug, expectWarning, throwOnWarnings } from './messages';
10
- export { Resolver, Options as ResolverOptions, ModuleRequest, Resolution, ResolverFunction, SyncResolverFunction, } from './module-resolver';
10
+ export { Resolver, Options as ResolverOptions, ModuleRequest, Resolution } from './module-resolver';
11
11
  export { ResolverLoader } from './resolver-loader';
12
12
  export { virtualContent } from './virtual-content';
13
13
  export type { Engine } from './app-files';
package/src/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,uCAOoB;AAHlB,qHAAA,yBAAyB,OAAA;AACzB,sGAAA,UAAU,OAAA;AACV,+GAAA,mBAAmB,OAAA;AAErB,qDAAkE;AAAzD,iHAAA,cAAc,OAAA;AAGvB,qCAAoE;AAAvC,8GAAA,mBAAmB,OAAA;AAChD,2DAAmE;AAA1D,uIAAA,OAAO,OAAoB;AACpC,mDAAwE;AAA/D,+HAAA,OAAO,OAAgB;AAChC,iDAAiE;AAAxD,oHAAA,OAAO,OAAuB;AACvC,uCAA4F;AAAnF,gGAAA,IAAI,OAAA;AAAE,uGAAA,WAAW,OAAA;AAAE,gGAAA,IAAI,OAAA;AAAE,iGAAA,KAAK,OAAA;AAAE,yGAAA,aAAa,OAAA;AAAE,2GAAA,eAAe,OAAA;AACvE,qDAO2B;AANzB,2GAAA,QAAQ,OAAA;AAOV,qDAAmD;AAA1C,iHAAA,cAAc,OAAA;AACvB,qDAAmD;AAA1C,iHAAA,cAAc,OAAA;AAGvB,8EAA8E;AAC9E,+DAA+D;AAC/D,8DAA4C","sourcesContent":["export {\n Packager,\n PackagerConstructor,\n Variant,\n applyVariantToBabelConfig,\n getAppMeta,\n getPackagerCacheDir,\n} from './packager';\nexport { HTMLEntrypoint, BundleSummary } from './html-entrypoint';\nexport { default as Stage } from './stage';\nexport { Asset, EmberAsset, ImplicitAssetPaths } from './asset';\nexport { default as Options, optionsWithDefaults } from './options';\nexport { default as toBroccoliPlugin } from './to-broccoli-plugin';\nexport { default as WaitForTrees, OutputPaths } from './wait-for-trees';\nexport { compile as jsHandlebarsCompile } from './js-handlebars';\nexport { todo, unsupported, warn, debug, expectWarning, throwOnWarnings } from './messages';\nexport {\n Resolver,\n Options as ResolverOptions,\n ModuleRequest,\n Resolution,\n ResolverFunction,\n SyncResolverFunction,\n} from './module-resolver';\nexport { ResolverLoader } from './resolver-loader';\nexport { virtualContent } from './virtual-content';\nexport type { Engine } from './app-files';\n\n// this is reexported because we already make users manage a peerDep from some\n// other packages (like embroider/webpack and @embroider/compat\nexport * from '@embroider/shared-internals';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,uCAOoB;AAHlB,qHAAA,yBAAyB,OAAA;AACzB,sGAAA,UAAU,OAAA;AACV,+GAAA,mBAAmB,OAAA;AAErB,qDAAkE;AAAzD,iHAAA,cAAc,OAAA;AAGvB,qCAAoE;AAAvC,8GAAA,mBAAmB,OAAA;AAChD,2DAAmE;AAA1D,uIAAA,OAAO,OAAoB;AACpC,mDAAwE;AAA/D,+HAAA,OAAO,OAAgB;AAChC,iDAAiE;AAAxD,oHAAA,OAAO,OAAuB;AACvC,uCAA4F;AAAnF,gGAAA,IAAI,OAAA;AAAE,uGAAA,WAAW,OAAA;AAAE,gGAAA,IAAI,OAAA;AAAE,iGAAA,KAAK,OAAA;AAAE,yGAAA,aAAa,OAAA;AAAE,2GAAA,eAAe,OAAA;AACvE,qDAAoG;AAA3F,2GAAA,QAAQ,OAAA;AACjB,qDAAmD;AAA1C,iHAAA,cAAc,OAAA;AACvB,qDAAmD;AAA1C,iHAAA,cAAc,OAAA;AAGvB,8EAA8E;AAC9E,+DAA+D;AAC/D,8DAA4C","sourcesContent":["export {\n Packager,\n PackagerConstructor,\n Variant,\n applyVariantToBabelConfig,\n getAppMeta,\n getPackagerCacheDir,\n} from './packager';\nexport { HTMLEntrypoint, BundleSummary } from './html-entrypoint';\nexport { default as Stage } from './stage';\nexport { Asset, EmberAsset, ImplicitAssetPaths } from './asset';\nexport { default as Options, optionsWithDefaults } from './options';\nexport { default as toBroccoliPlugin } from './to-broccoli-plugin';\nexport { default as WaitForTrees, OutputPaths } from './wait-for-trees';\nexport { compile as jsHandlebarsCompile } from './js-handlebars';\nexport { todo, unsupported, warn, debug, expectWarning, throwOnWarnings } from './messages';\nexport { Resolver, Options as ResolverOptions, ModuleRequest, Resolution } from './module-resolver';\nexport { ResolverLoader } from './resolver-loader';\nexport { virtualContent } from './virtual-content';\nexport type { Engine } from './app-files';\n\n// this is reexported because we already make users manage a peerDep from some\n// other packages (like embroider/webpack and @embroider/compat\nexport * from '@embroider/shared-internals';\n"]}
@@ -8,9 +8,6 @@ export interface Options {
8
8
  renameModules: {
9
9
  [fromName: string]: string;
10
10
  };
11
- activeAddons: {
12
- [packageName: string]: string;
13
- };
14
11
  resolvableExtensions: string[];
15
12
  appRoot: string;
16
13
  engines: EngineConfig[];
@@ -23,6 +20,7 @@ interface EngineConfig {
23
20
  activeAddons: {
24
21
  name: string;
25
22
  root: string;
23
+ canResolveFromFile: string;
26
24
  }[];
27
25
  fastbootFiles: {
28
26
  [appName: string]: {
@@ -32,33 +30,40 @@ interface EngineConfig {
32
30
  };
33
31
  root: string;
34
32
  }
35
- export interface ModuleRequest {
33
+ export interface ModuleRequest<Res extends Resolution = Resolution> {
36
34
  readonly specifier: string;
37
35
  readonly fromFile: string;
38
36
  readonly isVirtual: boolean;
39
37
  readonly meta: Record<string, unknown> | undefined;
38
+ readonly debugType: string;
39
+ readonly isNotFound: boolean;
40
+ readonly resolvedTo: Res | undefined;
40
41
  alias(newSpecifier: string): this;
41
42
  rehome(newFromFile: string): this;
42
43
  virtualize(virtualFilename: string): this;
43
44
  withMeta(meta: Record<string, any> | undefined): this;
45
+ notFound(): this;
46
+ defaultResolve(): Promise<Res>;
47
+ resolveTo(resolution: Res): this;
44
48
  }
45
49
  export type Resolution<T = unknown, E = unknown> = {
46
50
  type: 'found';
51
+ filename: string;
52
+ isVirtual: boolean;
53
+ result: T;
54
+ } | {
55
+ type: 'ignored';
47
56
  result: T;
48
57
  } | {
49
58
  type: 'not_found';
50
59
  err: E;
51
60
  };
52
- export type ResolverFunction<R extends ModuleRequest = ModuleRequest, Res extends Resolution = Resolution> = (request: R) => Promise<Res>;
53
- export type SyncResolverFunction<R extends ModuleRequest = ModuleRequest, Res extends Resolution = Resolution> = (request: R) => Res;
54
61
  export declare class Resolver {
55
62
  readonly options: Options;
56
63
  constructor(options: Options);
57
- beforeResolve<R extends ModuleRequest>(request: R): R;
58
- resolve<Req extends ModuleRequest, Res extends Resolution>(request: Req, defaultResolve: ResolverFunction<Req, Res>): Promise<Res>;
59
- resolveSync<Req extends ModuleRequest, Res extends Resolution>(request: Req, defaultResolve: SyncResolverFunction<Req, Res>): Res;
60
- private internalResolve;
61
- nodeResolve(specifier: string, fromFile: string): {
64
+ private beforeResolve;
65
+ resolve<ResolveResolution extends Resolution>(request: ModuleRequest<ResolveResolution>): Promise<ResolveResolution>;
66
+ nodeResolve(specifier: string, fromFile: string): Promise<{
62
67
  type: 'virtual';
63
68
  filename: string;
64
69
  content: string;
@@ -68,7 +73,7 @@ export declare class Resolver {
68
73
  } | {
69
74
  type: 'not_found';
70
75
  err: Error;
71
- };
76
+ }>;
72
77
  get packageCache(): RewrittenPackageCache;
73
78
  private logicalPackage;
74
79
  private generateFastbootSwitch;
@@ -90,8 +95,9 @@ export declare class Resolver {
90
95
  private handleRenaming;
91
96
  private resolveWithinMovedPackage;
92
97
  private preHandleExternal;
98
+ private locateActiveAddon;
93
99
  private external;
94
- fallbackResolve<R extends ModuleRequest>(request: R): R;
100
+ private fallbackResolve;
95
101
  private getEntryFromMergeMap;
96
102
  private withResolvableExtensions;
97
103
  private searchAppTree;