I have the following directory structure which follows Django's standard:
/my_site
/my_site
/my_app
/static
/my_app
/js
a.js
b.js
c.js
d.js
I have no problem specifying the static path in the html:
{% load staticfiles %}
<script src="{% static 'my_app/js/a.js' %}"></script>
However, there are some statements in file a.js
as follows:
var WORKER_PATH = 'b.js';
var encoderWorker = new Worker('c.js');
importScripts('d.js');
I was not able to set the paths for b.js
, c.js
, and d.js
correctly (but they all locate in the same directory!). How do I solve the problem?