diff --git a/blog.go b/blog.go index 7a6e881..698df68 100644 --- a/blog.go +++ b/blog.go @@ -14,7 +14,7 @@ import ( "cogentcore.org/core/htmlcore" "cogentcore.org/core/icons" "cogentcore.org/core/tree" - _ "cogentcore.org/core/yaegicore" + _ "cogentcore.org/lab/yaegilab" ) //go:embed content diff --git a/content/initial-release.md b/content/initial-release.md index 7f7a791..4a201b5 100644 --- a/content/initial-release.md +++ b/content/initial-release.md @@ -64,18 +64,22 @@ Again, you can modify any of the code above and immediately see the effects! You can even make interactive plots of data: -```Go -type Data struct { - Time float32 - Users float32 - Profit float32 +```Goal +func plot() { + type Data struct { + Time float32 + Users float32 + Profit float32 + } + + plotcore.NewEditor(b).SetSlice([]Data{ + {0, 500, 1520}, + {1, 800, 860}, + {2, 1600, 930}, + {3, 1400, 682}, + }) } -plotcore.NewPlotEditor(b).SetSlice([]Data{ - {0, 500, 1520}, - {1, 800, 860}, - {2, 1600, 930}, - {3, 1400, 682}, -}) +plot() ``` ## Key features