-
Notifications
You must be signed in to change notification settings - Fork 419
Closed
Labels
Milestone
Description
Related to #1386, can.stache
templates should be able to import components and modules they depend on.
For example, if a stache template looks like:
<div><can-slider></can-slider></div>
It will be transpiled to import can-slider
.
Also, a template might depend on helpers. These can be imported like:
<import from="my/helpers">
It's possible that a component's name doesn't match it's moduleName. We can also support the following:
<import from="components/slider" as="can-slider">
<can-slider></can-slider>
In this case can-slider
will not be imported, only components/slider
.
Other
- This will only happen for templates loaded with the can/view/stache/system extension.
- It's possible that we eventually support this happening with progressively loaded templates. However, can.view will need to support promises.