Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Try the following to help debug where the issue is precisely:</p> <ol> <li><p>Define a global function at the top of the plugin.js file and try calling it from the console. (you could just call an alert() here with similar results). If you're able to call this function, then the plugin file is being included as you claim. If not, then it's possible your assets path is off, so try adding a line like this to your config/application.rb</p> <pre><code>config.assets.paths &lt;&lt; Rails.root.join("Vendor", "assets", "javascripts") </code></pre></li> <li><p>Open your page in chrome or firebug with the javascript console open, and ensure that there are no javascript errors. It's possible that an error is preventing the plugin from loading correctly.</p></li> <li><p>Try using the simplest of plugins (like from <a href="http://docs.jquery.com/Plugins/Authoring" rel="nofollow">http://docs.jquery.com/Plugins/Authoring</a>) and if that works, then the issue is with the specific plugin you're trying to use.</p></li> <li><p>Try wrapping your plugin inside a document ready block, as it may require the DOM to be in place (note: this isn't always recommended, as it can cause an unoptimized page load, but it's worth a try)</p> <pre><code>$(function() { // put the plugin code here }); </code></pre></li> <li><p>Are you loading an other javascripts that use <code>$</code> in their namespace, like prototype?</p></li> <li><p>Is this a vanilla rails app, or a large, complex app? If it's the latter, see if you can reproduce the issue in a minimal failing example.</p></li> </ol>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload