Socket
Book a DemoInstallSign in
Socket

gulp-lodash-template

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-lodash-template

gulp plugin compile lodash template to a function

0.2.0
latest
Source
npmnpm
Version published
Weekly downloads
12
140%
Maintainers
1
Weekly downloads
 
Created
Source

gulp-lodash-template

gulp插件,将lodash模板文件预编译成function,支持JST、AMD和CommonJS输出

Precompile lodash.template to a function.

Install

npm install gulp-lodash-template --save-dev

Example

gulpfile.js

var template = require('gulp-lodash-template');

gulp.task('tmpl', function() {
  return gulp.src('./tmpl/*.html')
    .pipe(template({
      commonjs: true,
      // amd: true,
      strict: true
    }))
    .pipe(gulp.dest('./tmpl/'));
});

template(options)

options

Type: Object

options.strict

Type: Boolean Default: false

Add use strict; at the first line of the compiled template function.

options.es6module

Type: Boolean Default: false

options.commonjs

Type: Boolean Default: false

options.amd

Type: Boolean Default: false

options.namespace

Type: String Default: 'JST'

Keywords

lodash

FAQs

Package last updated on 29 Feb 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.