All Downloads are FREE. Search and download functionalities are using the official Maven repository.

node_modules.bower.lib.templates.helpers.colors.js Maven / Gradle / Ivy

var chalk = require('chalk');

var templateColors = [
    'yellow',
    'green',
    'cyan',
    'red',
    'white',
    'magenta'
];

function colors(Handlebars) {
    templateColors.forEach(function (color) {
        Handlebars.registerHelper(color, function (context) {
            return chalk[color](context.fn(this));
        });
    });
}

module.exports = colors;




© 2015 - 2024 Weber Informatics LLC | Privacy Policy