Hello,
I’m totally new in GoJS and try to run some simple example from your site. I use VS2013 and created simple MVC application. In Index.cshtml page I put the following:
@{
ViewBag.Title = "Home Page";
}
@section Scripts {
<script src="~/Scripts/go-1.7.11.js"></script>
<script type="text/javascript">
var $ = go.GraphObject.make;
var myDiagram =
$(go.Diagram, "myDiagramDiv",
{
initialContentAlignment: go.Spot.Center, // center Diagram contents
"undoManager.isEnabled": true // enable Ctrl-Z to undo and Ctrl-Y to redo
});
var myModel = $(go.Model);
// in the model data, each node is represented by a JavaScript object:
myModel.nodeDataArray = [
{ key: "Alpha" },
{ key: "Beta" },
{ key: "Gamma" }
];
myDiagram.model = myModel;
</script>
}
GoJS go!
<div id="myDiagramDiv" style="width: 400px; height: 150px; background-color: #DAE4E4;"></div>
When I run the application I’m getting “GoJS go!” text with grey empty rectangle without diagram below.
What I’m doing wrong?