Rails is not defined
// config/webpack/environment.js
const { environment } = require('@rails/webpacker')
const webpack = require('webpack')
environment.plugins.prepend('Provide',
new webpack.ProvidePlugin({
Rails: ['@rails/ujs']
})
)
module.exports = environment
Are there any code examples left?
New code examples in category Other