Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: mbostock/d3
...
head fork: mbostock/d3
Checking mergeability… Don't worry, you can still create the pull request.
  • 9 commits
  • 7 files changed
  • 0 commit comments
  • 2 contributors
View
6 bin/start
@@ -1,3 +1,7 @@
#!/usr/bin/env node
-console.log("d3 = (function(){\n var d3 = {version: " + JSON.stringify(require("../package.json").version) + "}; // semver");
+console.log("d3 = (function environment(d3_window){\n"
+ + " var d3 = {\n"
+ + " version: " + JSON.stringify(require("../package.json").version) + ",\n"
+ + " environment: environment\n"
+ + " };");
View
9 d3.js
@@ -1,11 +1,12 @@
-d3 = function() {
+d3 = function environment(d3_window) {
var d3 = {
- version: "3.1.7"
+ version: "3.1.7",
+ environment: environment
};
if (!Date.now) Date.now = function() {
return +new Date();
};
- var d3_document = document, d3_window = window;
+ var d3_document = d3_window.document;
try {
d3_document.createElement("div").style.setProperty("opacity", 0, "");
} catch (error) {
@@ -8549,4 +8550,4 @@ d3 = function() {
return request.responseXML;
}
return d3;
-}();
+}(window);
View
10 d3.min.js
5 additions, 5 deletions not shown
View
3  src/core/document.js
@@ -1,2 +1 @@
-var d3_document = document,
- d3_window = window;
+var d3_document = d3_window.document;
View
2  src/end.js
@@ -1,2 +1,2 @@
return d3;
-})();
+})(window);
View
7 src/start.js
@@ -1,2 +1,5 @@
-d3 = (function(){
- var d3 = {version: "3.1.7"}; // semver
+d3 = (function environment(d3_window){
+ var d3 = {
+ version: "3.1.7",
+ environment: environment
+ };
View
2  test/load.js
@@ -8,7 +8,7 @@ require("./XMLHttpRequest");
module.exports = function() {
var files = [].slice.call(arguments).map(function(d) { return "src/" + d; }),
expression = "d3",
- sandbox = {Date: Date}; // so we can use deepEqual in tests
+ sandbox = {Date: Date, window: null}; // so we can use deepEqual in tests
files.unshift("src/start");
files.push("src/end");

No commit comments for this range

Something went wrong with that request. Please try again.