Closed charypar closed 10 years ago
Ok, this is growing a bit. The dist task works pretty much as it should, except it required changing the way component templates are loaded.
Normal directive templates are precompiled using the $templateCache
and gulp, but we can't rely on that in components themselves. We can't load them from the server either though. We don't want to do an extra request for each component type.
So I switched to having the component templates in a string, where the component author is responsible for getting that string there. The first time component is rendered, that string is cached in the $templateCache
.
That unfortunately lead to changing the key by which components are handled in the componentService
from template
to a new id
.
Bottom line: just a refactoring, tests still pass and everything seems to work in gulp dev
.
BUT It should work in the newly created dist.html
as well and it doesn't. Well it does, except the medium editor, despite being initialized and not throwing any errors, doesn't work as it's supposed to. You can see the toolbar element in the DOM changing, but it's not visible. Styles are loaded correctly.
I'm not sure what this is and I'm probably too tired to figure it out today...
@musshush Can you take a look at what it could be...?
:shipit:
Dist task to build a distribution version of faber JS and CSS file. Creates four files in
/dist
:faber.js
- javascriptsfaber.min.js
- minified javascriptsfaber.css
- stylingfaber.min.css
- minified stylestodo