mirror of
https://github.com/xodio/xod.git
synced 2026-03-14 20:56:52 +01:00
Squashed commits: [af77987] refactor(xod-client, xod-client-browser, xod-client-electron): move common webpack config into xod-client, and extend it with specific options in other endpoint clients (browser/electron) [ddae62d] chore(xod): update `hm-def` to latest `0.2.1` version (that uses the same Ramda version) [5d80680] chore(xod): prepare all Ramda imports and some functions to migrate to 0.25.1 to be optimized better by tree-shaker (0.25.0 already has a features for better tree shaking, but it has a lot of bugs and perfomance regressions, so we’ll stay at 0.24.1 for a while) [9c05d6c] chore(xod-client-browser, xod-client-electron): enable UglifyJS webpack plugin to eliminate dead code and minify bundle (7.8MB -> 3.8MB) [cafbfcf] chore(xod, xod-client-browser, xod-client-electron): update webpack to version 3, update loaders,
21 lines
919 B
JavaScript
21 lines
919 B
JavaScript
/* eslint-disable import/no-extraneous-dependencies */
|
|
const merge = require('webpack-merge');
|
|
const webpack = require('webpack');
|
|
/* eslint-enable import/no-extraneous-dependencies */
|
|
const getBaseConfig = require('xod-client/webpack.config');
|
|
|
|
module.exports = merge.smart(getBaseConfig(__dirname), {
|
|
plugins: [
|
|
new webpack.DefinePlugin({
|
|
'process.env.NODE_ENV': JSON.stringify(process.env.NODE_ENV || 'development'),
|
|
'process.env.XOD_HM_DEF': JSON.stringify(process.env.XOD_HM_DEF || false),
|
|
'process.env.WHY_DID_YOU_UPDATE': JSON.stringify(process.env.WHY_DID_YOU_UPDATE || false),
|
|
|
|
'process.env.XOD_HOSTNAME': JSON.stringify(process.env.XOD_HOSTNAME || 'xod.io'),
|
|
'process.env.XOD_SITE_DOMAIN': JSON.stringify(''),
|
|
'process.env.XOD_FORUM_DOMAIN': JSON.stringify('https://forum.xod.io/'),
|
|
'process.env.XOD_UTM_SOURCE': JSON.stringify('ide-browser'),
|
|
}),
|
|
],
|
|
});
|