Skip to content

Instantly share code, notes, and snippets.

@MoacirPetry
Last active March 20, 2018 01:26
Show Gist options
  • Save MoacirPetry/aa42f6d66c54fe8aa46f31b1658e0bbf to your computer and use it in GitHub Desktop.
Save MoacirPetry/aa42f6d66c54fe8aa46f31b1658e0bbf to your computer and use it in GitHub Desktop.
Bootstrap and Ruby On Rails
If you created a project and configuration the bootstrap manually, your app/assets/javascripts/application.js maybe need like this:
// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, or any plugin's
// vendor/assets/javascripts directory can be referenced here using a relative path.
//
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// compiled file. JavaScript code in this file should be added after the last require_* statement.
//
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
// about supported directives.
//
//= require jquery.min
//= require rails-ujs
//= require turbolinks
//= require_tree .
//= require bootstrap.min
Because if you don't let config. of bootstrap in the last line, probably you'll have problems with your navbar, it came be not working with a collapse resource.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment