All Projects → trueadm → t7-precompiler

trueadm / t7-precompiler

Licence: other
t7 Precompiler

Programming Languages

184084 projects - #8 most used programming language

#t7.js Precompiler

This a Node precompiler for t7.js. This precompiler replaces all t7 template string instances in a given file and produces raw JavaScript output that can be interpreted at run-time for better start-up times and better performance.

It's highly recommended that you use this precompiler in your build pipeline when using t7 in production environments.

To install the t7-precompiler, simply run the following:

npm install -g t7-precompiler

To use the precompiler via command line use the t7-compiler command pass an input filename and an output t7 library syntax (React, Universal, Mitrhil, etc):

t7-compiler -i fileName.js -o react

The precompiled file should be output to the same directory.

Alternatively, you can require t7-precompiler in your Node module by using:

var precompiler = require("t7-precompiler");

precompiler.compile("var foo = 'bar';", "react");
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].