UNPKG

@gravityforms/gulp-tasks

Version:
38 lines (34 loc) 784 B
/** * External Dependencies */ import path from 'node:path'; import { fileURLToPath } from 'node:url'; import { createRequire } from 'node:module'; import getConfig from '../../../config.js'; const webpack = createRequire( import.meta.url )( 'webpack' ); const __dirname = path.dirname( fileURLToPath( import.meta.url ) ); const { config } = getConfig(); /** * Internal Dependencies */ import rules from '../rules/index.js'; export default { resolve: { extensions: [ '.js', '.jsx', '.json', '.pcss' ], }, resolveLoader: { modules: [ path.resolve( `${ __dirname }/../../../`, 'node_modules' ), config.paths.npm, ], }, module: { rules, }, plugins: [ new webpack.IgnorePlugin( { resourceRegExp: /^\.\/locale$/, contextRegExp: /moment$/, } ), ], };