ext-coffeesctipt

Transpile coffeescript files into javascript.

Usage

rtb.coffeeScript(options={});

Options

options will override rtb.moduleOptions.

rtb.buildOptions (BuildConfig.buildOptions)

OptionTypeDefaultDescription
babelbooleanfalseEnable babel.
lintbooleanfalseEnable linter

rtb.moduleOptions (BuildConfig.moduleOptions)

propertytypedefaultdescription
coffeeObject{}Options to gulp-coffee. Default becomes { bare: true } if rtb.buildOptions.babel is true
coffeelintObject{}Options to gulp-coffeelint.
babelObject{}Options to gulp-babel.

Example

const tron = require('gulp-tron');
const coffee = {
name: 'coffee',
builder: (rtb) => rtb.src().coffee().dest(),
src: ['assets/coffee/**/*.coffee'],
dest: 'www/js',
outFile: 'sample-coffee.js',
buildOptions: { babel: true },
npmInstall: ['@babel/preset-env']
};

Notes

This extension is for custom processing. Use GCoffeeScriptBuilder for coffeescript file processiing.