I'm using ES6 and a dozen or so modules, which are all working fine, but on adding a new github module (github:mbostock/topojson) which requires the amd loader I am running into problems:
For example, "d3" creates the following loader:
module.exports = require("github:mbostock/d3@3.5.6/d3");
which means I can do the following successfully:
import "d3";
But "github:mbostock/topojson" creates:
define(["github:mbostock/topojson@1.6.19/topojson"], function(main) { return main; });
So when I do the following, the package is loaded, but no globals are defined:
import 'mbostock/topojson';
NOTE, the correct "globals' are present in main above, but I don't know how to import these.
I'm using ES6 and a dozen or so modules, which are all working fine, but on adding a new github module (github:mbostock/topojson) which requires the amd loader I am running into problems:
For example, "d3" creates the following loader: module.exports = require("github:mbostock/d3@3.5.6/d3");
which means I can do the following successfully: import "d3";
But "github:mbostock/topojson" creates: define(["github:mbostock/topojson@1.6.19/topojson"], function(main) { return main; });
So when I do the following, the package is loaded, but no globals are defined: import 'mbostock/topojson';
NOTE, the correct "globals' are present in main above, but I don't know how to import these.
Do I need to create a shim?