Activity
I've been working on getting Bootstrap 4 up and running with Rails 6 Beta 3 and have a simple Popper.js I am testing, that still isn't firing. I noticed in webpack\environment.js
I had another version of this different from yours. Can you explain why you have append
instead of prepend
const webpack = require('webpack')
environment.plugins.prepend(
'Provide',
new webpack.ProvidePlugin({
$: 'jquery',
jQuery: 'jquery',
jquery: 'jquery',
'window.jQuery': 'jquery',
Popper: ['popper.js', 'default']
})
)
module.exports = environment
Neither solution has worked for me yet, so just wondering where I am going off the Rails so to speak.
My application.js
currently has the following:
import 'bootstrap/dist/js/bootstrap.bundle'
import 'jquery/dist/jquery.slim'
import 'popper.js/dist/esm/popper'
require("@rails/ujs").start()
require("@rails/activestorage").start()
I watched this last night and got tripped up because my localhost isn't the default. After some fumbling I added this to my development.rb file. config.action_cable.allowed_request_origins = ['http://localhost:1701']