JS flowchart Solutions GoJS

GoJs Profile

A realization of interactive class diagram (such as flow charts, tree map, diagram, force mapping, etc.) JS libraries
GoJS rely on HTML5, so please ensure your browser version supports HTML5, of course, to load the library.

First of all personally recommend to download the official version [Examples offline access network is not very good so it is recommended in view of cache downloaded], followed by the hope that you have a Google browser! (Easy to read without effort translated into Chinese!)

Download interface https://gojs.net/latest/download.html

click here to download


 <!-- 调式或开发模式下请使用 go-debug.js -->
  

 <!-- f非调式或开发模式下请使用 go.js -->
  

Each GoJS chart must be contained within a specified width and height of the container div

<!-- 这个DIV必须指定宽高,否者不会被渲染出来
     我们通常为DIV设置一个背景颜色以便于我们更便捷的观察 -->
<div id="myDiagramDiv"
     style="width:400px; height:150px; background-color: #DAE4E4;"></div>

In the JS code section, you need to pass a div id as a parameter to create a chart, not much said here in a very clear case to look at!

var $ = go.GraphObject.make;
var myDiagram =
  $(go.Diagram, "myDiagramDiv");

PS: All GoJS properties and methods are under go this namespace. All GoJS class name, for example, Diagram, Node, Panel, Shape, TextBlock also go to use as a prefix

Getting Started tutorial to see here

Guess you like

Origin www.cnblogs.com/userzf/p/11327024.html