| Page 1 of 1 | [ 4 posts ] |
|
I understand and successfully use a version of
http://yuilibrary.com/yui/docs/yui/loader-resolve.html for my own project. However, I don't want to have to add the dependency information for my own modules manually - because that's 151 modules (and growing) and changes more or less frequently. A few months ago I looked into this for the first time, and I think I only found some Python script somewhere in YUI3 to calculate the meta-information the YUI3 loader uses to compute the dependencies. Isn't there an easier way? Since I'm already running this node.js script, and since the modules are just JS functions, whose 4th argument is the module meta info object with the "requires" array... Sure, I could write something myself to iterate over all my JS files (YUI3 modules), run the YUI.add() function which I cleverly "captured", providing my own, only to get at the 4th parameter, and from there add module meta info manually to the loader. But maybe someone has already done this (or sees an issue in my idea) - I'm terribly lazy |
|
Never mind - I've done it myself already. Lazy or not, have to get this done
|
|
If you can, you should share this script.
I recently re-wrote the python script in JS: https://github.com/yui/yui3/blob/master ... ta_join.js My goal is to have a command line tool that does this and inspects local meta-data to generate a module with custom loader meta-data. |
|
Well, okay, here is a sample. Has lots of comments so no need to say anything else here.
http://pastebin.com/A2qSC35E PS: I just filed ticket #2532498 for a severe issue, its currently assigned to you. |
| Page 1 of 1 | [ 4 posts ] |
| You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum |
© 2006-2013 Yahoo! Inc. All rights reserved.
All code on this site is licensed under the BSD License unless stated otherwise.
About This Site · Security Contact Info
Powered by phpBB® Forum Software © phpBB Group