django-dajaxice icon indicating copy to clipboard operation
django-dajaxice copied to clipboard

Unable to find JS static files (fix)

Open ksurya opened this issue 11 years ago • 2 comments

I have tried to use {% dajaxice_js_import %} to import JS files as in the directory ./dajaxice/templates/dajaxice/. The template tag is able to render the respective html element but not able to load the file!

This issue is raised many times on google-groups too

Django unable to find those static files

The possible fix:

rename the directory templates to static. So, the directory where these files will now be ./dajaxice/static/dajaxice/

Now when people run manage.py collectstatic they will pretty able to load all these static files into their project and thus the urls work

ksurya avatar May 13 '13 16:05 ksurya

@jorgebastida can you please comment on it

ksurya avatar Jun 02 '13 10:06 ksurya

They're not static files but templates. The js is generated from the template with your decorated ajax functions.

ghost avatar Sep 04 '13 20:09 ghost