Refactor so that small apps don't pull in the old renderer as well as some classic things#21462
Refactor so that small apps don't pull in the old renderer as well as some classic things#21462NullVoxPopuli wants to merge 1 commit into
Conversation
📊 Size reportTarball size — dist/dev 0.2%↑
dist/prod 0.2%↑
smoke-tests/v2-app-template/dist 0.04%↑
smoke-tests/v2-app-hello-world-template/dist -4.06%↓
🤖 This report was automatically generated by wyvox/pkg-size |
baa4932 to
d68b86d
Compare
/* @__PURE__ */ decorationd68b86d to
ad5de44
Compare
b4cf812 to
5d75be0
Compare
which modules have side-effects
5d75be0 to
16c8800
Compare
| hash, | ||
| 'unique-id': uniqueId, | ||
| }; | ||
|
|
There was a problem hiding this comment.
two branches with the same code
| // class; deriving it from the definition (rather than importing it from | ||
| // the module that defines `Helper`) keeps this module from pulling in | ||
| // the classic object model when no classic helpers are in use. | ||
| let manager = getInternalHelperManager(definition); |
There was a problem hiding this comment.
I think this is safe because of the isClassicHelper check above
| } | ||
|
|
||
| lookupBuiltInHelper(name: string): HelperDefinitionState | null { | ||
| assert( |
There was a problem hiding this comment.
not sure how I feel about this -- -prefixed things are private.
at the same time, we do eventually want to enable routing things for folks using renderComponent, but we only want that stuff to become available when importing router stuff
There was a problem hiding this comment.
direct extraction from renderer.ts
There was a problem hiding this comment.
used in the main/classic renderer here: https://github.com/emberjs/ember.js/pull/21462/changes#diff-cdf95f0c6c10226a54fbac271478aaa1defd908f0f998fec0f484e52d2544184R211
Still exploring ways to hint to bundlers that they can remove unused things