Closed BenJackGill closed 2 months ago
When you turn off ssr
option (which is not enabled by default) in the module config, <VChart>
will become a plain client chart. Whether you turn on SSR or not, the usage of <VChart>
is the same except that you don't need to assign an initial size when SSR is off. The initial size is only required in SSR.
//nuxt.config.ts
export default defineNuxtConfig({
modules: ['nuxt-echarts'],
echarts: {
- ssr: true,
},
})
The bar chart in the demo is based on <VChart>
.
Here is also another example. I use client-only <VChart>
in this starter template.
https://github.com/kingyue737/vitify-nuxt/blob/main/pages/dashboard.vue
Lots of good examples in the demo and on Github for different SSR scenarios, but none for a plain standard client side setup. Would be good to see the idiomatic way of doing that.