I am working with d3.js for Data visualization. I am getting the warning shown in the following image. Does anyone have the idea why is this happening and how can I solve this? The message shown in the error is following
mutating the [[Prototype]] of an object will cause your code to run very slowly; instead create the object with the correct initial [[Prototype]] value using Object.create
I am working with d3.js for Data visualization. I am getting the warning shown in the following image. Does anyone have the idea why is this happening and how can I solve this? The message shown in the error is following
mutating the [[Prototype]] of an object will cause your code to run very slowly; instead create the object with the correct initial [[Prototype]] value using Object.create
Share
Improve this question
edited Feb 23, 2015 at 15:21
Bergi
666k161 gold badges1k silver badges1.5k bronze badges
asked Feb 23, 2015 at 14:36
user4556747user4556747
7
- Does this happen when you load the library, or does it e from your usage? Which line triggers this message? – Bergi Commented Feb 23, 2015 at 14:51
- See this post on what the message means and by what kind of code it is caused. – Bergi Commented Feb 23, 2015 at 14:52
- The error is shown when I launch the page and no data are shown – user4556747 Commented Feb 23, 2015 at 14:53
- Here is the jsfiddle . Where can such error occur in my code? – user4556747 Commented Feb 23, 2015 at 15:02
- That fiddle doesn't even import d3?! In what browser are you getting this warning? – Bergi Commented Feb 23, 2015 at 15:04
1 Answer
Reset to default 8Does anyone have the idea why is this happening
Looks like it's d3's fault. They seem to use it to subclass arrays here:
// Until ECMAScript supports array subclassing, prototype injection works well.
var d3_subclass = function(object, prototype) {
object.__proto__ = prototype;
};
how can I solve this?
Ignore the warning. Or file a bug against have a look at this issue of d3.js.