amd-optimize icon indicating copy to clipboard operation
amd-optimize copied to clipboard

Support for require plugins

Open normanrz opened this issue 11 years ago • 11 comments

e.g. text

Log Time

normanrz avatar Feb 20 '14 14:02 normanrz

Any chances to see this feature soon? :) Cool plugin by the way. Thanks for sharing your work.

Tarabyte avatar Oct 17 '14 12:10 Tarabyte

I don't have any schedule for this, and it is quite a chunk of work. What kind of requireJS plugins are you using?

normanrz avatar Oct 17 '14 15:10 normanrz

"it is quite a chunk of work" it looks like it is. All plugins heavily rely on r.js infrastructure. Basically I am using text and tpl to load html strings and templates. And was actually planning to use i18n for globalization.

Tarabyte avatar Oct 17 '14 16:10 Tarabyte

What kind of requireJS plugins are you using?

The text plugin is a staple for loading HTML templates in a single page application. We're also using the require-less plugin.

The lack of support for loader plugins is the only thing that's stopping us from switching to amd-optimize right now :(

Awesome, noble effort! I wish I'd have the time to chip in with adding support for loader plugins.

atesgoral avatar Oct 31 '14 17:10 atesgoral

+1 for text plugin. I think it's the main one...

engyii avatar Nov 05 '14 16:11 engyii

Do the plugins generally depend on stuff beyond the documented 'loader plugin API'? I can see that being a fair bit of work to implement, but a comment here above makes me wonder if it goes beyond that. Are there any specific stumbling blocks in the way, aside from the amount of work involved?

anarchodin avatar Nov 27 '14 17:11 anarchodin

I suppose it's mainly the documented plugin loader API and regular node APIs (which are available of course).

normanrz avatar Dec 01 '14 15:12 normanrz

+1 for text plugin. At least this one. Even as a dirty hack or whatever :) just make it work.

kirill-konshin avatar Dec 10 '14 07:12 kirill-konshin

I have tried to use loader config property, but text!... files even don't appear in callbacks...

kirill-konshin avatar Dec 10 '14 07:12 kirill-konshin

I've added PR which solves at least a part of this issue: https://github.com/scalableminds/amd-optimize/pull/31 Brute-force implementation of requirejs-text plugin

kirill-konshin avatar Dec 10 '14 10:12 kirill-konshin

Thanks to @kirill-konshin for making the text loader!

normanrz avatar Dec 10 '14 12:12 normanrz