- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

edrivera3
Builder
09-14-2015
11:22 AM
Hi
I am trying to load d3 library in a js wrapper, but I am encountering an error. I believe the cause of the problem is a wrong path. The js wrapper and the d3,js are located at apps/myappname/django/myappname/static/myappname.
This is the beginning of the wrapper:
define(function(require, exports, module) {
var _ = require('underscore');
var d3 = require(["d3.js"]);
var mvc = require('splunkjs/mvc');
var SimpleSplunkView = require('splunkjs/mvc/simplesplunkview');
...
...
This is the error displayed on the console:
Script error for: d3.js http://requirejs.org/docs/errors.html#scripterror
1 Solution
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

edrivera3
Builder
09-14-2015
12:29 PM
Hi
I solved my problem:
var d3 = require('myappname/d3');
Note: This works if you are using Django Binding.
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

edrivera3
Builder
09-14-2015
12:29 PM
Hi
I solved my problem:
var d3 = require('myappname/d3');
Note: This works if you are using Django Binding.
