rayfarias56 / shpe

shpe uiuc's website
http://www.shpe-uiuc.org
2 stars 0 forks source link

Capistrano Development Duplicate Assets (Drop-down not working) #140

Closed rayfarias56 closed 8 years ago

rayfarias56 commented 8 years ago

Documenting a weird bug and its even weirder fix.

Issue: Navbar dropdown doesn't open on develop.shpe-uiuc.org

This issue doesn't appear in prod or staging. It's caused by duplicate jquery assets provided by the server, so a double execution of checking for removable "opens" (the drop-down works by closing all possible dropdowns and then adding to the clicked one).

The issue was resolved at one point by adding config.assets.compile = false (see 8a93dde)

Which has to be false so that the /public assets aren't served along with a compiled asset.

Inspiration for the fix (but not the same behavior) was found here: http://cbron.github.io/blog/2013/06/04/duplicate-assets-on-a-staging-environment-with-capistrano/