0.1.7 • Published 10 years ago

gulp-melchior v0.1.7

Weekly downloads
1
License
MIT
Repository
github
Last release
10 years ago

Gulp Melchior

Optimize (concatenate) melchior.js projects using Gulp plugin.

Getting Started

If you haven't used Gulp before, be sure to check out the Getting Started guide, as it explains how to create a Gulpfile as well as install and use Gulp plugins. Once you're familiar with that process, you may install this plugin with this command:

npm install gulp-melchior --save-dev

Once the plugin has been installed, it may be enabled inside your Gulpfile with this line of JavaScript:

var melchior = require('gulp-melchior');

Melchior task

This is basic task to concatenate all files in Melchior project

gulp.task('melchior', function(){
  gulp.src('config.js')
    .pipe(melchior())
    .pipe(gulp.dest('build'));
});

Options

melchior plugin can be initialized with options object. In example:

.pipe(melchior({
  path: 'folder/'
}));

path: String


This option is used when file with Melchior config isn't in the same folder as Gulp(this is normal).

Folder structure:

├──gulpfile.js
└──app
   ├──js
   │  ├──config.js
   │  ├──app.js
   │  └──module.js
   ├──html
   └──css

MelchiorJS config:

melchiorjs.config({
  paths: {
    'module': 'js/module.js'
  }
});

Gulp Task example:

gulp.task('melchior', function(){
  gulp.src('app/js/config.js')
    .pipe(melchior({
      path: 'app/'
    }))
    .pipe(gulp.dest('build'));
});

Please end path with correct path delimeter character.

Concatenation of non-local files

Right now non-local files don't concatenated in result file.

0.1.7

10 years ago

0.1.6

10 years ago

0.1.5

10 years ago

0.1.4

10 years ago

0.1.3

10 years ago

0.1.2

10 years ago

0.1.1

10 years ago

0.1.0

10 years ago