How to use the kcd-scripts/config.getRollupConfig function in kcd-scripts

To help you get started, we’ve selected a few kcd-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 paypal / glamorous / rollup.config.js View on Github external
const rollupConfig = require('kcd-scripts/config').getRollupConfig()

const tiny = process.env.TINY
const esm = process.env.BUILD_FORMAT === 'esm'

Object.assign(rollupConfig, {
  external: ['preact', 'react', 'glamor', 'prop-types'],
  output: [
    Object.assign(rollupConfig.output[0], {
      exports: tiny || !esm ? 'default' : 'named',
      name: 'glamorous',
      globals: {
        react: 'React',
        preact: 'preact',
        glamor: 'Glamor',
        'prop-types': 'PropTypes',
      },
github deseretdigital / dayzed / rollup.config.js View on Github external
const rollupConfig = require('kcd-scripts/config').getRollupConfig();

Object.assign(rollupConfig, {
  external: ['preact', 'react', 'prop-types'],
  output: [
    Object.assign(rollupConfig.output[0], {
      globals: {
        react: 'React',
        preact: 'preact',
        'prop-types': 'PropTypes'
      }
    })
  ]
});

module.exports = rollupConfig;
github sastan / react-render-callback / rollup.config.js View on Github external
module.exports = () => {
  const getRollupConfig = require('kcd-scripts/config').getRollupConfig

  const rollupConfig = getRollupConfig()

  replace(rollupConfig.plugins, 'babel', () => {
    const babel = require('rollup-plugin-babel')

    return babel({
      exclude: 'node_modules/**',
      babelrc: true,
      runtimeHelpers: true,
    })
  })

  return rollupConfig
}
github arthurdenner / react-semantic-ui-datepickers / rollup.config.js View on Github external
import copy from 'rollup-plugin-copy';
import postcss from 'rollup-plugin-postcss';

const rollupConfig = require('kcd-scripts/config').getRollupConfig();

module.exports = {
  input: 'src/index.js',
  external: ['react', 'react-dom', 'prop-types', 'semantic-ui-react'],
  output: Object.assign(rollupConfig.output[0], {
    file: 'dist/react-semantic-ui-datepickers.js',
    sourcemap: true,
  }),
  plugins: [
    copy({
      'src/locales': 'dist/locales',
      'src/index.d.ts': 'dist/index.d.ts',
    }),
    postcss({ extract: true, minimize: true }),
  ].concat(rollupConfig.plugins),
};