2020-11-30 06:28:29 -06:00
|
|
|
const copy = require('@neutrinojs/copy');
|
|
|
|
|
2020-12-02 16:34:52 -06:00
|
|
|
const splitConfig = require('../../config/split-config');
|
2020-12-02 02:20:53 -06:00
|
|
|
const pkg = require('./package.json');
|
|
|
|
|
2020-12-02 16:34:52 -06:00
|
|
|
const clientMains = [
|
|
|
|
'client',
|
|
|
|
];
|
2020-12-01 18:23:49 -06:00
|
|
|
|
2020-12-02 16:34:52 -06:00
|
|
|
module.exports = splitConfig(pkg, clientMains);
|
2020-12-01 18:23:49 -06:00
|
|
|
|
2020-12-02 16:34:52 -06:00
|
|
|
module.exports[0].use.push(copy({
|
2020-11-30 06:28:29 -06:00
|
|
|
patterns: ['index.js', 'index.ejs', 'latus.js'].map((path) => ({
|
|
|
|
from: `src/client/${path}`,
|
|
|
|
to: 'client',
|
2020-12-17 02:08:16 -06:00
|
|
|
})).concat(['.neutrinorc.js', 'client-plugins.js', 'webpack.config.js'].map((path) => ({
|
2020-12-06 23:36:32 -06:00
|
|
|
from: `src/build/${path}`,
|
|
|
|
to: 'build',
|
|
|
|
}))),
|
2020-11-30 06:28:29 -06:00
|
|
|
}));
|