| Page 1 of 1 | [ 10 posts ] |
|
I'm looking for a way to skip the build step altogether during custom module development. It does not make sense for me to use ant (a Java application) in order to build the JavaScript modules when I only want to test some changes.
So, can I configure the loader to load the source files, without building anything? If not, is there another loader that can do this? |
|
Loader can do this, but your source files are not in the proper format to load. They lack the required `YUI.add` wrapper call. If you add the YUI.add calls to your source files, then sure it can. But you will need to manually remove them before you build with builder.
|
|
You mean I have to point the loader to the 'src' folder instead of the 'build' folder and write all my JavaScript into a single file, right? But that's unfortunate, because than I can't split my module code into different JavaScript files as required.
It would be nice if the loader could load both source and build files.. |
|
Loader can, but your dev environment needs to be able to produce a valid module js file.
|
|
You should look at Shifter (http://github.com/davglass/shifter) it builds modules really fast compared to Builder.
|
|
@kenjiru: If you don't want to have to rebuild and are simply testing modules you are developing, you can always use something like Dav described in this gist https://gist.github.com/1275713. Of course you can add custom css as a separate module with "type:'css'" in a module.
|
Juan Ignacio DopazoYUI Contributor
|
davglass wrote: You should look at Shifter (http://github.com/davglass/shifter) it builds modules really fast compared to Builder. Love the --strict option! |
|
Is not exactly what I meant, but Shifter looks way better than Builder, because it drops the Java requirement.
It would still be nice not to require any build step at all during development. The build process looks more like packing than building, as everything you need to run the application is already in the source folder. @Todd Smith: I'm already doing this now, thank you for the advice. |
Juan Ignacio DopazoYUI Contributor
|
davglass wrote: You should look at Shifter (http://github.com/davglass/shifter) it builds modules really fast compared to Builder. How fast is Shifter? Is the --watch mode faster than Alt+Tab + F5? Last edited by jdopazo on Mon Aug 27, 2012 5:51 am, edited 1 time in total. |
|
There is a difference between loading your raw source and loading a built module. Many module require more than one JS file in a certain order. Plus a module with a skin or a language pack needs a generated set of source files that are not the same as they are in the src directory.
Using shifter to build a module that is only one JS file is probably overboard, but if you have several JS files, skin, language files (and eventually pre-compiled templates) you are doing yourself a diservice by not building per change |
| Page 1 of 1 | [ 10 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