Skip to content
This repository has been archived by the owner on Jan 13, 2020. It is now read-only.

Latest commit

 

History

History
71 lines (54 loc) · 1.36 KB

README.md

File metadata and controls

71 lines (54 loc) · 1.36 KB

GruntJS-In-3-Steps

Tutorial for the FrankenJS group

A GruntJS Automation Approach for a remarkjs Presentation


###BEFORE YOU START

  • Start by CLONING of BRANCHING the repository.
  • Install NPM Dependencies npm install
  • Editing the CSS
  • Add Image Resources

#Step 1 - Gruntfile.js

  • Load Tasks
// Individually  
grunt.loadNpmTasks('grunt-contrib-__plugin__');
// All At Once
require('load-grunt-tasks')(grunt);
// Visit: https://www.npmjs.org/package/load-grunt-tasks

#Step 2 - Configure Plug-ins

 grunt.initConfig({});
  • Expose Additional Variables
grunt.initConfig({
    pkg: grunt.file.readJSON("package.json"),
    /* and so on */
});

Step 3 - Register Tasks

  • Always have a default task
grunt.registerTask('default', function(){
    /* some logic */
});
  • Alias Tasks
grunt.registerTask('TaskList', ['first:task','second:task','third']);

More about GruntJS