The script tags:
<script src="~/Scripts/curl.js"></script>
<script src="~/Areas/Analytics/Scripts/Charting/ChartingMain.js"></script>
ChartingMain:
curl({ baseUrl: "/" }, ["Areas/Analytics/Scripts/Charting/ChartingApp"], function (ChartingApp) {
var chartingApp = new ChartingApp();
});
ChartingApp:
define([
"require",
"exports",
"Areas/Analytics/Scripts/Charting/ChartViewModel",
"Areas/Analytics/Scripts/Routing/RouteManager",
"Areas/Analytics/Scripts/Charting/FusionCharts/DualYCombination2D",
"Areas/Analytics/Scripts/Charting/FusionCharts/Column2D",
"Areas/Analytics/Scripts/Charting/KendoDataViz/DataVizConfigGenerator",
"Areas/Analytics/Scripts/Charting/KendoDataViz/DataVizRenderer",
"Areas/Analytics/Scripts/Charting/FusionCharts/FusionChartRenderer"
], function(
require,
exports,
ChartViewModel,
RouteManagerImpl,
DualYCombination2D,
Column2D,
DataVizConfigGenerator,
DataVizRenderer,
FusionChartRenderer
) {
//some code
});
If I look in the network tab of the chrome debugger, I can see that the charting app modules are getting loaded. When I put break points in the modules, they get hit and return. The majority of modules return constructor functions, however when the ChartingApp define callback runs, all the modules in the callback are just base Objects with no parameters.
I was previously using requirejs to load these modules and everything worked. What might I be missing here?
The script tags:
ChartingMain:
ChartingApp:
If I look in the network tab of the chrome debugger, I can see that the charting app modules are getting loaded. When I put break points in the modules, they get hit and return. The majority of modules return constructor functions, however when the ChartingApp define callback runs, all the modules in the callback are just base Objects with no parameters.
I was previously using requirejs to load these modules and everything worked. What might I be missing here?