Socket
Book a DemoInstallSign in
Socket

gulp-extract-text

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-extract-text

By Ralph Crisostomo - 2016/04/05

latest
Source
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

gulp-extract-text

By Ralph Crisostomo - 2018/01/07

Description

A Gulp plugin for extracting text from a file.

Install

npm install --save-dev gulp-extract-text

Extract files

Extract text from different files like .txt, .html, .css, .js and etc.

Parameters

let extract_text_params = {
    pattern_start       : "<pattern start>",
    pattern_end         : "<pattern end>"
}

Basic Usage

Let say we want to extract all the text inside <head> tag and export it to dist directory.

const gulp              = require('gulp');
const extract_text      = require('gulp-extract-text');

let extract_text_params = {
    pattern_start       : "<head>",
    pattern_end         : "</head>"
}

gulp.task('deploy',function(){
    gulp.src(['src/index.html'])
    .pipe(extract_text(extract_text_params))
    .pipe(gulp.dist('./dist'))
});

Keywords

gulp

FAQs

Package last updated on 07 Jan 2018

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.