bearded-octo-robot
A crazy fast async JavaScript pre-processor with an even crazier name.
Install
stable
npm install bor
edge
npm install https://github.com/daxxog/bearded-octo-robot/tarball/master
Usage
source file
/*!! include "includeme.js" !!*//*!! include "includeme.js" !!*//*!! define CONST "HELLO !!*/ /*!! if CONST "HELLO !!*/console;/*!! endif CONST "HELLO !!*/
calling
var bor = ;bor;
Or in HTML
<script type="text/javascript">
<!--!! include "inline.js" !!-->
</script>
<!--!! include "include.html" !!-->
Features
- Global defines
- Basic if/endif macro that comments out text
- Auto comment style detection
- Inline includes
- Caches includes for faster processing
- Not just for JavaScript, works in HTML, XML, css, C, etc. Submit a pull request to support more languages :)
- Everything is processed in parallel using async