Compiles OneJS html templates and generates a variety of output.
npm install gulp-onejs-compiler> Compiler OneJS templates into javascript for project merging. See the onejs-compiler project for more details on the template format.
NOTE: Until onejs-compiler is published to npm, you must use npm link:
```
git clone onejs-compiler
cd onejs-compiler
npm link
cd..
git clone gulp-onejs-compiler
npm i
npm link onejs-compiler
Once this module has been published:
Install with npm
``
$ npm install --save-dev gulp-onejs-compiler
`js
var gulp = require('gulp'),
compiler = require('gulp-onejs-compiler');
gulp.task('default', function() {
return gulp.src('src/*.html')
.pipe(compiler())
.pipe(gulp.dest('dist'));
});
`
#### options.typeScriptViewFileFormat
Type: String{{templateName}}.ts
Default:
The format for view file's filename. Leaving this blank suppresses generation.
#### options.typeScriptViewModelFileFormat
Type: StringI{{templateName}}Model.ts
Default:
The format for view model interface file's filename. Leaving this blank suppresses generation.
`javascript``
paths: {
onejs: '../onejs/',
defaultView: '../{{viewType}}/{{viewType}}'
}
Specifies the default paths to use in the imports. {{viewType}} will be replaced with the
classname of the current view.
MIT © David Zearing