mirror of
https://github.com/verdaccio/verdaccio.git
synced 2024-11-17 07:45:52 +01:00
558d78f32a
* feat: flexible template generator and manifest * chore: add changeset * chore: restore dep * chore: add docs * chore: update snapshots * chore: update docker examples for v5 * chore: refactor web module * chore: format * chore: refactor web api endpoints * test: add test for user login web * chore: refactor endpoints * chore: fix merge * chore: fix merge * Update ci.yml * chore: test * chore: add static * chore: update script * chore: fix e2e * chore: fix method * docs: update v5 relative docker example * chore: update html render * chore: update style * Update .prettierignore * chore: update changeset * chore: use pnpm6 on run test temporary ci * chore: drop node 16 for pnpm 6 * chore: update ci * chore: update ci * chore: update ci * chore: update ci * chore: remove circle ci * chore: better url prefix handling * chore: format code * chore: remove test node 10 * docs: add docker v5 relative revers proxy example * chore: use base html tag * chore: update test
82 lines
1.6 KiB
JavaScript
82 lines
1.6 KiB
JavaScript
const StyleLintPlugin = require('stylelint-webpack-plugin');
|
|
|
|
const env = require('../config/env');
|
|
|
|
module.exports = {
|
|
entry: `${env.SRC_ROOT}/index.tsx`,
|
|
|
|
output: {
|
|
path: `${env.APP_ROOT}/static/`,
|
|
filename: '[name].[fullhash].js',
|
|
publicPath: '-/static/',
|
|
},
|
|
|
|
resolve: {
|
|
extensions: ['.wasm', '.mjs', '.js', '.jsx', '.ts', '.tsx'],
|
|
modules: ['node_modules'],
|
|
alias: {
|
|
'verdaccio-ui/components': `${env.SRC_ROOT}/components`,
|
|
'verdaccio-ui/design-tokens': `${env.SRC_ROOT}/design-tokens`,
|
|
'verdaccio-ui/utils': `${env.SRC_ROOT}/utils`,
|
|
},
|
|
},
|
|
|
|
plugins: [
|
|
new StyleLintPlugin({
|
|
files: ['src/**/styles.ts'],
|
|
failOnError: false,
|
|
emitErrors: true,
|
|
}),
|
|
],
|
|
|
|
optimization: {
|
|
runtimeChunk: {
|
|
name: 'runtime',
|
|
},
|
|
splitChunks: {
|
|
chunks: 'all',
|
|
cacheGroups: {
|
|
commons: {
|
|
test: /[\\/]node_modules[\\/]/,
|
|
name: 'vendors',
|
|
chunks: 'initial',
|
|
},
|
|
},
|
|
},
|
|
},
|
|
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.jsx?$/,
|
|
exclude: /node_modules/,
|
|
use: 'babel-loader',
|
|
},
|
|
{
|
|
test: /\.m?js/,
|
|
resolve: {
|
|
fullySpecified: false,
|
|
},
|
|
},
|
|
{
|
|
test: /\.(jpe?g|png|gif|svg)$/,
|
|
type: 'asset/inline',
|
|
},
|
|
{
|
|
test: /\.css$/,
|
|
type: 'asset/inline',
|
|
},
|
|
/* Typescript loader */
|
|
{
|
|
test: /\.tsx?$/,
|
|
use: 'babel-loader',
|
|
exclude: /node_modules/,
|
|
},
|
|
],
|
|
},
|
|
|
|
stats: {
|
|
children: false,
|
|
},
|
|
};
|