diff --git a/packages/@ember/engine/lib/engine-parent.ts b/packages/@ember/engine/lib/engine-parent.ts index 6c988263ef5..cabd777b07b 100644 --- a/packages/@ember/engine/lib/engine-parent.ts +++ b/packages/@ember/engine/lib/engine-parent.ts @@ -1,7 +1,7 @@ /** @module @ember/engine */ -import type EngineInstance from './instance'; +import type EngineInstance from '../instance'; export const ENGINE_PARENT = Symbol('ENGINE_PARENT'); diff --git a/rollup.config.mjs b/rollup.config.mjs index 40588430934..e7b775fee36 100644 --- a/rollup.config.mjs +++ b/rollup.config.mjs @@ -48,27 +48,7 @@ function esmConfig() { ]; return { - onLog(level, log, handler) { - switch (log.code) { - case 'CIRCULAR_DEPENDENCY': - if (log.ids.some((id) => id.includes('node_modules/rsvp/lib/rsvp'))) { - // rsvp has some internal cycles but they don't bother us - return; - } - process.stderr.write( - `Circular dependency:\n${log.ids.map((id) => ' ' + id).join('\n')}\n` - ); - throw new Error(`Circular dependencies are forbidden`); - case 'EMPTY_BUNDLE': - // Some of our entrypoints are type-only and result in empty bundles. - // We prune the actual empty files elsewhere in this config (see - // pruneEmptyBundles). This silences the warning from rollup about - // them. - return; - default: - handler(level, log); - } - }, + onLog: handleRollupWarnings, input: { ...renameEntrypoints(exposedDependencies(), (name) => join('packages', name, 'index')), ...renameEntrypoints(packages(), (name) => join('packages', name)), @@ -126,6 +106,7 @@ function legacyBundleConfig(input, output, { isDeveloping, isExternal }) { interop: 'esModule', }, + onLog: handleRollupWarnings, plugins: [ amdDefineSupport(), ...(isDeveloping ? [concatenateAMDEntrypoints()] : []), @@ -516,3 +497,25 @@ function pruneEmptyBundles() { }, }; } + +function handleRollupWarnings(level, log, handler) { + switch (log.code) { + case 'CIRCULAR_DEPENDENCY': + if (log.ids.some((id) => id.includes('node_modules/rsvp/lib/rsvp'))) { + // rsvp has some internal cycles but they don't bother us + return; + } + process.stderr.write( + `Circular dependency:\n${log.ids.map((id) => ' ' + id).join('\n')}\n` + ); + throw new Error(`Circular dependencies are forbidden`); + case 'EMPTY_BUNDLE': + // Some of our entrypoints are type-only and result in empty bundles. + // We prune the actual empty files elsewhere in this config (see + // pruneEmptyBundles). This silences the warning from rollup about + // them. + return; + default: + handler(level, log); + } +}