How to use the resolve-scripts.merge function in resolve-scripts

To help you get started, we’ve selected a few resolve-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 reimagined / resolve / examples / shopping-list-tutorial / lesson-7 / run.js View on Github external
break
    }

    case 'build': {
      await build(merge(defaultResolveConfig, appConfig, prodConfig))
      break
    }

    case 'start': {
      await start(merge(defaultResolveConfig, appConfig, prodConfig))
      break
    }

    case 'test:functional': {
      await runTestcafe({
        resolveConfig: merge(
          defaultResolveConfig,
          appConfig,
          testFunctionalConfig
        ),
        functionalTestsDir: 'test/functional',
        browser: process.argv[3]
      })
      break
    }

    default: {
      throw new Error('Unknown option')
    }
  }
})().catch(error => {
  // eslint-disable-next-line no-console
github reimagined / resolve / examples / hacker-news / run.js View on Github external
dropSnapshots: true,
          dropReadModels: true,
          dropSagas: true
        })

        await runTestcafe({
          resolveConfig,
          functionalTestsDir: 'test/functional',
          browser: process.argv[3]
        })

        break
      }

      case 'import': {
        const config = merge(baseConfig, devConfig)
        await reset(config, {
          dropEventStore: true,
          dropSnapshots: true,
          dropReadModels: true,
          dropSagas: true
        })

        const importConfig = merge(baseConfig, devConfig, {
          eventBroker: { launchBroker: false },
          apiHandlers: [
            {
              method: 'POST',
              path: 'import_events',
              controller: {
                module: 'import/import_api_handler.js',
                options: {}
github reimagined / resolve / examples / hacker-news / run.js View on Github external
await importEventStore(resolveConfig, { importFile })

        break
      }

      case 'export-event-store': {
        const resolveConfig = merge(baseConfig, devConfig)

        const exportFile = process.argv[3]
        await exportEventStore(resolveConfig, { exportFile })

        break
      }

      case 'test:functional': {
        const resolveConfig = merge(baseConfig, testFunctionalConfig)
        await reset(resolveConfig, {
          dropEventStore: true,
          dropSnapshots: true,
          dropReadModels: true,
          dropSagas: true
        })

        await runTestcafe({
          resolveConfig,
          functionalTestsDir: 'test/functional',
          browser: process.argv[3]
        })

        break
      }
github reimagined / resolve / examples / shopping-list-advanced / run.js View on Github external
method: 'POST',
          callback: 'domain/auth/route_register_callback.js'
        },
        {
          path: 'auth/local/login',
          method: 'POST',
          callback: 'domain/auth/route_login_callback.js'
        }
      ]
    }
  ])

  switch (launchMode) {
    case 'dev': {
      await watch(
        merge(defaultResolveConfig, appConfig, devConfig, authModule),
        adjustWebpackConfigs.bind(null, devConfig)
      )
      break
    }

    case 'build': {
      await build(
        merge(defaultResolveConfig, appConfig, prodConfig, authModule),
        adjustWebpackConfigs.bind(null, prodConfig)
      )
      break
    }

    case 'cloud': {
      await build(
        merge(defaultResolveConfig, appConfig, cloudConfig, authModule),
github reimagined / resolve / examples / with-postcss / run.js View on Github external
case 'start': {
        await start(merge(defaultResolveConfig, appConfig, prodConfig))
        break
      }

      case 'import-event-store': {
        const resolveConfig = merge(defaultResolveConfig, appConfig, devConfig)

        const importFile = process.argv[3]

        await importEventStore(resolveConfig, { importFile })
        break
      }

      case 'export-event-store': {
        const resolveConfig = merge(defaultResolveConfig, appConfig, devConfig)

        const exportFile = process.argv[3]

        await exportEventStore(resolveConfig, { exportFile })
        break
      }

      case 'test:functional': {
        const resolveConfig = merge(
          defaultResolveConfig,
          appConfig,
          testFunctionalConfig
        )

        await reset(
          resolveConfig,