gulp-coffee-includer

1.1.1 • Public • Published

gulp-coffee-includer

Using gulp-coffee-includer you can finally include files with proper intendation.

Current support

Node 6.0 - 9.0

Installation

npm install gulp-coffee-includer --save-dev

Usage

gulpfile.js

const gulp = require('gulp');
const CI = require('gulp-coffee-includer');
const coffee = require('gulp-coffee');

gulp.task('build', function(){
  gulp.src('main.coffee')
  .pipe(CI)
  .pipe(coffee())
  .pipe(gulp.dest('build'))
});

Include statements

main.coffee

foo = ->
  bar()
  #intend include statement according to current scope
  #=include <path/to/file.coffee>

file.coffee

do awsome_things in coding unless
  awsome_things is boring

output.coffee

foo = ->
  bar()
  #file.coffee contents is placed, where you need it!
  do awsome_things in coding unless
    awsome_things is boring

Looking for CLI version?

License

MIT

Package Sidebar

Install

npm i gulp-coffee-includer

Weekly Downloads

2

Version

1.1.1

License

none

Last publish

Collaborators

  • zydnar