Documentation
¶
Overview ¶
Package plotly provides a godom plugin for Plotly.js integration. Plotly's basic bundle is embedded and injected automatically — no CDN or manual <script> tag required. Users configure charts using plain Go structs that map to Plotly's declarative JSON API.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Plugin godom.PluginFunc = func(eng *godom.Engine) {
eng.RegisterPlugin("plotly", plotlyLibJS, bridgeJS)
}
Plugin registers Plotly with a godom Engine.
Functions ¶
This section is empty.
Types ¶
type Chart ¶
type Chart struct {
Data []M `json:"data"`
Layout M `json:"layout,omitempty"`
Config M `json:"config,omitempty"`
}
Chart holds the configuration for a Plotly chart. Data holds the trace array and Layout controls appearance. Config is optional Plotly config (e.g. responsive, displayModeBar).
Click to show internal directories.
Click to hide internal directories.