mirror of
https://github.com/kingomarnajjar/gatsby-starter-netlify-cms.git
synced 2026-07-26 06:37:25 +10:00
30 lines
579 B
JavaScript
30 lines
579 B
JavaScript
// This webpack config is used to compile the JS for the CMS
|
|
const path = require('path');
|
|
|
|
module.exports = {
|
|
entry: './cms.js',
|
|
output: {
|
|
filename: 'cms.bundle.js',
|
|
path: path.resolve(__dirname, '../static/admin/'),
|
|
},
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.jsx?$/,
|
|
exclude: /node_modules/,
|
|
use: {
|
|
loader: 'babel-loader',
|
|
options: {
|
|
presets: ['babel-preset-env', 'babel-preset-react'],
|
|
},
|
|
},
|
|
},
|
|
],
|
|
},
|
|
resolve: {
|
|
extensions: [
|
|
'.js',
|
|
'.jsx',
|
|
],
|
|
},
|
|
};
|