Sha256: fe5e01baceb8a4e3b5e753917dcf7236670583b8befa96a1d616b736524e869a

Contents?: true

Size: 1.25 KB

Versions: 50

Compression:

Stored size: 1.25 KB

Contents

const webpack = require('webpack')
const { environment } = require('@rails/webpacker')
const jquery = require('./plugins/jquery')
const { VueLoaderPlugin } = require('vue-loader')
const vue = require('./loaders/vue')
const ManifestPlugin = require('webpack-manifest-plugin')
const customConfig = require('./custom')
const dotenv = require('dotenv')
dotenv.config({path: __dirname + '/.env'})
environment.plugins.insert(
	"Environment",
	 new webpack.EnvironmentPlugin(process.env)
  )

const babelLoader = environment.loaders.get('babel')
babelLoader.exclude = []
environment.splitChunks()

// Merge custom config
environment.config.merge(customConfig)

environment.plugins.prepend('VueLoaderPlugin', new VueLoaderPlugin())
environment.plugins.prepend('Provide',
  new webpack.ProvidePlugin({
    $: 'jquery/src/jquery',
    jQuery: 'jquery/src/jquery',
    Popper: ['popper.js', 'default']
  })
);

environment.loaders.prepend('vue', vue)

// Create a global var in Webpack for Adobe Analytics
new webpack.DefinePlugin({
  'ADOBE_LAUNCH_PRIMARY_CATEGORY': JSON.stringify(process.env.ADOBE_LAUNCH_PRIMARY_CATEGORY),
});

environment.loaders.get('sass').use.splice(-1, 0, {
  loader: 'resolve-url-loader',
});

environment.plugins.prepend('jquery', jquery)
module.exports = environment

Version data entries

50 entries across 50 versions & 1 rubygems

Version Path
station-0.5.16 lib/nexmo_developer/config/webpack/environment.js
station-0.5.15 lib/nexmo_developer/config/webpack/environment.js
station-0.5.14 lib/nexmo_developer/config/webpack/environment.js
station-0.5.13 lib/nexmo_developer/config/webpack/environment.js
station-0.5.12 lib/nexmo_developer/config/webpack/environment.js
station-0.5.11 lib/nexmo_developer/config/webpack/environment.js
station-0.5.10 lib/nexmo_developer/config/webpack/environment.js
station-0.5.9 lib/nexmo_developer/config/webpack/environment.js
station-0.5.8 lib/nexmo_developer/config/webpack/environment.js
station-0.5.7 lib/nexmo_developer/config/webpack/environment.js
station-0.5.6 lib/nexmo_developer/config/webpack/environment.js
station-0.5.5 lib/nexmo_developer/config/webpack/environment.js
station-0.5.4 lib/nexmo_developer/config/webpack/environment.js
station-0.5.3 lib/nexmo_developer/config/webpack/environment.js
station-0.5.2 lib/nexmo_developer/config/webpack/environment.js
station-0.5.1 lib/nexmo_developer/config/webpack/environment.js
station-0.5.0 lib/nexmo_developer/config/webpack/environment.js
station-0.4.9 lib/nexmo_developer/config/webpack/environment.js
station-0.4.8 lib/nexmo_developer/config/webpack/environment.js
station-0.4.7 lib/nexmo_developer/config/webpack/environment.js