Feature: allowAppImports - #587
Conversation
|
TODO list items:
|
| } | ||
|
|
||
| get allowAppImports(): string[] { | ||
| // only apps (not addons) are allowed to set this |
There was a problem hiding this comment.
I discussed this feature a while ago with @ef4 within CrowdStrike, and IIRC we came to the conclusion that also addons should be able to do this. Example use case would be to have a v1 addon import its own css-modules based CSS (to get rid of ember-css-modules), so the consuming app could already switch to optimized Embroider (which ember-css-modules does not support) without requiring all addons to migrate to v2.
FWIW, this (v1 addon support of this feature) is not anymore a priority for us, but maybe it's still good to allow this!?
There was a problem hiding this comment.
This is a good point.
I want to use this feature to make a package like https://github.com/cardstack/glimmer-scoped-css work in classic builds, and for that story to be complete you'd want a v1 addon to be able to use it too.
34653b9 to
9c6306b
Compare
f521109 to
bfe310a
Compare
| let host: AppInstance & { | ||
| trees: { | ||
| app: Node; | ||
| }; | ||
| } = _host as any; |
There was a problem hiding this comment.
Since you force the type, could this work/be considered:
| let host: AppInstance & { | |
| trees: { | |
| app: Node; | |
| }; | |
| } = _host as any; | |
| let host = _host as AppInstance & { | |
| trees: { | |
| app: Node; | |
| }; | |
| }; |
This is taking over from #586 👍
Fixes #565
Fixes #158