UNPKG

@kanopi/pack

Version:

Pre-packaged Webpack 5 configuration with extendable configuration to coordinate loaders and rules for common web stacks

14 lines (13 loc) 326 B
const BabelLoader = require('../loaders/babel'); module.exports = (environment) => { const { scripts: { useJsxSyntax } } = environment; return [ { test: useJsxSyntax ? /\.jsx?$/ : /\.js$/, exclude: /node_modules/, use: BabelLoader(environment) } ] }