Unintended FastBoot dependencies under Embroider
See original GitHub issueHi,
I have a question about content of dist/package.js
under FastBoot. It looks that the dist/package.json
is extended version of package.json
with FastBoot extras.
In classic build the dist/package.json
contains dependencies
based on fastbootDependencies
in package.json
, then npm install
is required to run in dist/
(eq. fastboot-s3-downloader).
{
"dependencies": {
"abortcontroller-polyfill": "^1.4.0",
"node-fetch": "^2.6.1"
}
}
When using Embroider the dist/package.json
contains also references for in-repo add-ons, thus later run of npm install
fails.
{
"dependencies": {
"aws": "*",
"build": "*",
"dom-attrs": "*",
"gtm": "*",
"headers": "*",
"manifest": "*",
"one-signal": "*",
"redirect-support": "*",
"sitemap": "*",
"test-fastboot": "*",
"version": "*",
"abortcontroller-polyfill": "^1.4.0",
"node-fetch": "^2.6.1"
}
}
How these extra dependencies should be handled in FastBoot?
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
embroider/SPEC.md at main - GitHub
the fastboot transform is used to neuter whole dependencies in fastboot. This can be handled by ECMA dynamic import() instead. most other occurrences...
Read more >Build Issues - Ember.JS
Topic Replies Views Activity
About the Build Issues category 0 578 April 9, 2018
Importing host app components in Embroider Addon 1 106 October 26,...
Read more >@embroider/macros | Yarn - Package Manager
Fast, reliable, and secure dependency management.
Read more >EmberConf 2021 Notes - Alex DiLiberto
Glimmer 2: drop in replacement in Ember 2.10 (complete rewrite ... Status of major ecosystem projects like Fastboot, Embroider and Engines?
Read more >Newest 'ember.js' Questions - Stack Overflow
How to create a dependency graph of components in Ember? I'm trying to navigate through a large Ember ... Module parse failed: Unexpected...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ah, that is a good question. Some additional config is going to be required to make that work. You would need to tell webpack to treat them as
externals
. Something like this:Thanks for clarification, before I dive in I’ve made an example of the changes.
this.fastboot.isFastBoot
ortypeof FastBoot !== 'undefined'
will work properly ormacroCondition(getGlobalConfig().fastboot?.isRunning)
should be used instead to avoid bundlingsomething
into browser assets?