Open stefanpenner opened 8 years ago
@nathanhammond the tests have been updated to work with some known add-on limitations. There still exist further issues, but this now works around a resolving bug in ember-cli. So it is at-least closing to possibly working.
Im heading to a meeting, and wont be looking at this for the next hour or so. My latest changes have been updated.
Please review the new lib structure, especially how in-repo modules dependencies are setup. Including that they declare their dependency on ember-browserify itself (this way ember browserify atleast runs for them).
There are more issues yet, although this is getting closer...
The next step on this, which I've started, is to switch to pushing a preprocessor into the parent addon and away from postprocessTree
. See #109.
Some notes: browserify/browserify.js
are being written (i believe):
We most likely need to address:
Something to consider:
host
Order of execution:
Can use treeForVendor
to "correctly" provide Browserify modules for all things but the root
. This will eliminate the need to use .import
.
Looking into available workarounds for the root
, whose preprocessors run far too late. Also investigating the degree of change to Ember CLI and risk in changing this behavior to match the nested story.
TL;DR this opens support (improved support, not quite perfect) for add-on and nested add-on usage.
The aim is to mangle imports/exports such that, each browserify bundle will uniquely identify each module by version. The associated importing module will also refer to that version. This will in-theory allow duplicate versions to co-exist. We would prefer this not to work, but shrug.... π₯
browserify/browserify.js
imports.