0.4.6 • Published 1 year ago

@bipboys/webpack-stats-plugin v0.4.6

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

Stats Resolver for React SSR

Stats resolver function for Webpack

Usage

npm i @bipboys/webpack-stats-plugin

Use "StatsWriterPlugin" for export assets to *.json

const {StatsWriterPlugin} = require('@bipboys/webpack-stats-plugin');

module = {
  // webpack config
  plugins: [
    new StatsWriterPlugin({
      filename: 'stats.json',
      fields: [
        'errors',
        'warnings',
        'assets',
        'hash',
        'publicPath',
        'outputPath',
        'namedChunkGroups'
      ]
    })
  ]
};

Somewhere in your server:

import {getScripts} from '@bipboys/webpack-stats-plugin';

// Get Scripts and Links from stats.json
const {scriptsAssets, stylesAssets} = await getScripts(manifest, assetName);
0.4.6

1 year ago

0.4.5

1 year ago

0.4.4

2 years ago

0.4.3

2 years ago

0.3.6

2 years ago

0.3.5

2 years ago

0.3.8

2 years ago

0.3.7

2 years ago

0.4.1

2 years ago

0.4.0

2 years ago

0.4.2

2 years ago

0.3.4

2 years ago

0.3.2

2 years ago