-
Notifications
You must be signed in to change notification settings - Fork 157
Angular Template cache is now supported #152
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
It fixes #151.
Hi @slavafomin thanks for your time, as described in #150 to merge a templateCache feature it has to be an option that you can toggle via attribute.
tooltip-template-cache="true"
and it caches the template you pass through 👍
Hey @45kb! Why do you want it to be optional? Angular itself and many other popular modules are using template cache automatically, without the any opt-ins. If user don't want to use template cache he just could skip adding anything to it. If you're concerned about $templateCache.put
that I call, we could omit this line or make it optional.
@slavafomin i can agree with you but the real correct way is simple, set an attribute, if the attribute is present or true, you store and retrieve the template in and from the cache, otherwise you don't have to interact with cache.
It's not my own view or choice, it's how we should release features to make everyone happy and for any possible use case, i hope you'll understand.
Then be sure to look, there is a tooltipConfProvider somewhere which must be updated the same ;)
Uh oh!
There was an error while loading. Please reload this page.
I've implemented support for Angular template cache. Now, the module first tries to load specified template from cache and then falls back to
$http.get
. When template is actually loaded from server it is saved in the cache for further use. This is the expected behavior for any Angular module that uses templates.