Gathering detailed insights and metrics for asset-config-webpack-plugin
Gathering detailed insights and metrics for asset-config-webpack-plugin
Gathering detailed insights and metrics for asset-config-webpack-plugin
Gathering detailed insights and metrics for asset-config-webpack-plugin
@akqa-frontline/asset-config-webpack-plugin
![GitHub](https://img.shields.io/github/license/akqa-frontline/frontline) ![npm (scoped)](https://img.shields.io/npm/v/@akqa-frontline/asset-config-webpack-plugin)
add-asset-html-webpack-plugin
Add a JS or CSS assets to a generated HTML file
webpack-manifest-plugin
A Webpack Plugin for generating Asset Manifests
terser-webpack-plugin
Terser plugin for webpack
npm install asset-config-webpack-plugin
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
642 Stars
249 Commits
39 Forks
24 Watching
11 Branches
18 Contributors
Updated on 16 Nov 2024
JavaScript (80.99%)
TypeScript (18.72%)
HTML (0.28%)
Cumulative downloads
Total Downloads
Last day
-69%
9
Compared to previous day
Last week
-27.6%
42
Compared to previous week
Last month
1.5%
207
Compared to previous month
Last year
-43.8%
3,186
Compared to previous year
1
Creating webpack loader configurations can be quite time consuming.
This project tries to provide best practices for the most common loader requirements: ts
, js
, scss
, fonts
and images
.
Instead of copying loader configs from github and stackoverflow you could just add one of the following plugins.
The compatible version of webpack to each plugin may vary and is documented in each package.json
file under the peerDependencies
property.
npx generate-webpack-config
Alternatively you can also use the online config tool to get started.
Webpack itself provides many defaults so you are able to run the common-config-webpack-plugin
without a webpack.config file:
1npm i --save-dev webpack webpack-cli common-config-webpack-plugin 2 3npx webpack --plugin common-config-webpack-plugin
You can even setup an entire development server without configuration:
1npm i --save-dev webpack common-config-webpack-plugin html-webpack-plugin 2 3webpack-dev-server --plugin common-config-webpack-plugin --plugin html-webpack-plugin
Many projects will need some project specific options. The common-config-webpack-plugin
suite is designed to be plugable so you will be able to pick only what you need and combine it with your configuration. By default the plugin configuration will adjust depending on your webpack mode setting.
common-config-webpack-plugin
├── js-config-webpack-plugin
├── ts-config-webpack-plugin
├── scss-config-webpack-plugin
└── asset-config-webpack-plugin
├── font-config-webpack-plugin
└── image-config-webpack-plugin
To get started you can just add all common-config-webpack-plugin
parts at once.
1const CommonConfigWebpackPlugin = require('common-config-webpack-plugin'); 2 3module.exports = { 4 plugins: [new CommonConfigWebpackPlugin()], 5};
Which would be exactly the same as
1const JsConfigWebpackPlugin = require('js-config-webpack-plugin'); 2const TsConfigWebpackPlugin = require('ts-config-webpack-plugin'); 3const ScssConfigWebpackPlugin = require('scss-config-webpack-plugin'); 4const FontConfigWebpackPlugin = require('font-config-webpack-plugin'); 5const ImageConfigWebpackPlugin = require('image-config-webpack-plugin'); 6 7module.exports = { 8 plugins: [ 9 new JsConfigWebpackPlugin(), 10 new TsConfigWebpackPlugin(), 11 new ScssConfigWebpackPlugin(), 12 new FontConfigWebpackPlugin(), 13 new ImageConfigWebpackPlugin(), 14 ], 15};
🗒️js-config-webpack-plugin
Readme
⚙️development webpack.config.js
⚙️production webpack.config.js
The js-config-webpack-plugin
is a modified version of the create-react-app best practices.
By default the plugin configuration will adjust depending on your webpack mode setting.
1const JsConfigWebpackPlugin = require('js-config-webpack-plugin'); 2module.exports = { 3 plugins: [new JsConfigWebpackPlugin()], 4};
🗒️ts-config-webpack-plugin
Readme
⚙️development webpack.config.js
⚙️production webpack.config.js
The ts-config-webpack-plugin
is a modified version of the ts-loader best practices.
By default the plugin configuration will adjust depending on your webpack mode setting.
1const TsConfigWebpackPlugin = require('ts-config-webpack-plugin'); 2module.exports = { 3 plugins: [new TsConfigWebpackPlugin()], 4};
🗒️scss-config-webpack-plugin
Readme
⚙️development webpack.config.js
⚙️production webpack.config.js
The scss-config-webpack-plugin
is a modified version of the create-react-app best practices.
By default the plugin configuration will adjust depending on your webpack mode setting.
1const ScssConfigWebpackPlugin = require('scss-config-webpack-plugin'); 2module.exports = { 3 plugins: [new ScssConfigWebpackPlugin()], 4};
🗒️asset-config-webpack-plugin
Readme
The asset-config-webpack-plugin
is just a wrapper around the font-config-webpack-plugin
and the image-config-webpack-plugin
.
1const AssetConfigWebpackPlugin = require('asset-config-webpack-plugin'); 2module.exports = { 3 plugins: [new AssetConfigWebpackPlugin()], 4};
🗒️font-config-webpack-plugin
Readme
⚙️development webpack.config.js
⚙️production webpack.config.js
The font-config-webpack-plugin
will allow you to use woff-fonts.
1const FontConfigWebpackPlugin = require('font-config-webpack-plugin'); 2module.exports = { 3 plugins: [new FontConfigWebpackPlugin()], 4};
🗒️image-config-webpack-plugin
Readme
⚙️development webpack.config.js
⚙️production webpack.config.js
The image-config-webpack-plugin
will allow you to use images from within js and css files.
1const ImageConfigWebpackPlugin = require('image-config-webpack-plugin'); 2module.exports = { 3 plugins: [new ImageConfigWebpackPlugin()], 4};
The common-config-webpack-plugin
suite provides typechecks and integration tests for the loader configurations for Windows and Unix.
The common-config-webpack-plugin
has a direct dependencies to babel and ts.
However if you need to pick a specific version you can use the js-config-webpack-plugin
or ts-config-webpack-plugin
which use peer-dependencies instead.
The common-config-webpack-plugin
is MIT licensed.
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 4/11 approved changesets -- score normalized to 3
Reason
0 commit(s) and 1 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
95 existing vulnerabilities detected
Details
Score
Last Scanned on 2024-11-18
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More