const path = require('path'); module.exports = ({entries, paths, root, rules}) => { rules.push({ test: new RegExp('@avocado/packages/entity/trait/traits.avopack.js$'), use: { loader: '@avocado/core/webpack/autoreg', options: { paths, registrar: { function: 'registerTrait', module: '@avocado/entity', }, root, type: 'trait', }, }, }); entries.push('@avocado/entity/trait/traits.avopack'); };