docs: update documents

This commit is contained in:
vicanso 2021-12-26 16:09:42 +08:00
parent 6ff0499839
commit 8c7222a7ce
2 changed files with 37 additions and 2 deletions

View file

@ -398,7 +398,7 @@ func TestParseECharsOptions(t *testing.T) {
}, options)
}
func BenchmarkEChartsRender(b *testing.B) {
func BenchmarkEChartsRenderPNG(b *testing.B) {
for i := 0; i < b.N; i++ {
_, err := RenderEChartsToPNG(`{
"title": {
@ -419,3 +419,25 @@ func BenchmarkEChartsRender(b *testing.B) {
}
}
}
func BenchmarkEChartsRenderSVG(b *testing.B) {
for i := 0; i < b.N; i++ {
_, err := RenderEChartsToSVG(`{
"title": {
"text": "Line"
},
"xAxis": {
"type": "category",
"data": ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"]
},
"series": [
{
"data": [150, 230, 224, 218, 135, 147, 260]
}
]
}`)
if err != nil {
panic(err)
}
}
}