Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

With include_javascripts, is there a way to get just the URL? #206

Open
bhellman1 opened this issue Sep 19, 2011 · 1 comment
Open

With include_javascripts, is there a way to get just the URL? #206

bhellman1 opened this issue Sep 19, 2011 · 1 comment

Comments

@bhellman1
Copy link

I need to use $.getScript, To use getScript I would need just the URL from Jammit. Is this possible?

$.getScript('ajax/test.js', function(data, textStatus){
console.log('Load was performed.');
});

Thanks

@danielstocks
Copy link

Here's what i did:

     <%= javascript_path (Jammit.asset_url("desktop", :js)) %>

Assumes you have :desktop JavaScript packages in config/assets.yml

cheers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants