
Security News
Crates.io Users Targeted by Phishing Emails
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
@webpack-blocks/extract-text
Advanced tools
Use this block to extract text (for example CSS) from the bundle into a separate file. Uses Extract Text Plugin.
# for webpack v3
npm install --save-dev @webpack-blocks/extract-text
# for webpack v2 install the last v1.0 beta version
npm install --save-dev @webpack-blocks/extract-text@^1.0.0-beta.2
const { createConfig } = require('@webpack-blocks/webpack')
const extractText = require('@webpack-blocks/extract-text')
module.exports = createConfig([
/* ... */
extractText('path/to/output.file')
])
Most likely you’ll use it to extract styles:
const { createConfig, match, env } = require('@webpack-blocks/webpack')
const { css } = require('@webpack-blocks/assets')
const extractText = require('@webpack-blocks/extract-text')
module.exports = createConfig([
match('*.css', [
css(),
// Filename defaults to 'css/[name].[contenthash:8].css'
// Extract styles only in production mode
// to keep styles hot reload in development
env('production', [extractText()])
])
])
Check out the
Released under the terms of the MIT license.
FAQs
Webpack block for the Extract Text Plugin.
The npm package @webpack-blocks/extract-text receives a total of 319 weekly downloads. As such, @webpack-blocks/extract-text popularity was classified as not popular.
We found that @webpack-blocks/extract-text demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
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.
Security News
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
Product
Socket now lets you customize pull request alert headers, helping security teams share clear guidance right in PRs to speed reviews and reduce back-and-forth.
Product
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.