Open brianmhunt opened 11 years ago
I think that's a pretty reasonable request. Out of the box, it does support the AMD plugin in 0.4.1.
Do you think there's any value in adding a direct-plugin, which would enable localStorage support and some of Inject's other features such as pointcuts?
Thanks for the feedback!
I think a direct plugin could benefit from being added to Inject proper if localStorage could be used, but let me know what you think.
There are a few stages of coffee-script
building that a loader could perform:
Parts 1 & 2 are the sine qua non of the plugin. Part 4.a would definitely provide an incredible performance boost if it eliminated the download and compilation parts, and it sounds like localStorage/Inject could provide that sort of caching.
Parts 3, 4.b and 4.c would be coffee-script developers' heaven, but obviously they are somewhat more challenging.
EDIT One prerequisite to using coffee-script with Inject is that the CoffeeScript compiler would need to be downloaded. The Inject plugin could detect whether there is a window.CoffeeScript
object, or make 'coffee-script' a dependency of the cs!
plugin, but I have not wrapped my head around how that work work.
For my purposes I am simply including <script src='coffee-script.js'></script>
before the Inject require.run
call i.e. not loading coffee-script with Inject. In an ideal world, coffee-script would be loaded by Inject.
It would be wonderful to have support for the CoffeeScript
cs!
plugin. Example implementations: