How to use the cozy-scripts/utils/merge.mergeAppConfigs function in cozy-scripts

To help you get started, we’ve selected a few cozy-scripts examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github cozy / cozy.github.io / en / cozy-banks / webpack.config.js View on Github external
loader: 'imports-loader?css=./cozy-bar.css'
      }
    ]
  }
}

const appOnlyConfigs = [
  require('cozy-scripts/config/webpack.config.react'),
  require('cozy-scripts/config/webpack.config.cozy-ui'),
  require('cozy-scripts/config/webpack.config.cozy-ui.react'),
  require('cozy-scripts/config/webpack.config.css-modules'),
  require('cozy-scripts/config/webpack.config.pictures'),
  barConfig
]

const common = mergeAppConfigs(
  [
    require('cozy-scripts/config/webpack.config.eslint'),
    require('cozy-scripts/config/webpack.config.base'),
    ...(target !== 'services' ? appOnlyConfigs : []),
    addAnalyzer ? require('cozy-scripts/config/webpack.config.analyzer') : null,
    require('./config/webpack.config.base'),
    require('./config/webpack.config.manual-resolves'),
    require('./config/webpack.config.plugins'),
    require('cozy-scripts/config/webpack.config.manifest'),
    hotReload ? require(`./config/webpack.config.hot-reload`) : null
  ].filter(Boolean)
)

const targetCfg = require(`./config/webpack.target.${target}`)

const withTarget = merge.strategy({

cozy-scripts

<a href="https://www.npmjs.com/package/cozy-scripts"> <img src="https://img.shields.io/npm/v/cozy-scripts.svg" alt="npm version" /> </a> <a href="https://github.com/CPatchane/create-cozy-app/blob/master/packages/cozy-scripts/LICENSE"> <img src="https:

MIT
Latest version published 10 months ago

Package Health Score

50 / 100
Full package analysis

Similar packages