Open EdozdeDandez opened 6 years ago
So I think the error is coming from this:
You are creating the lava
javscript object yourself, and then trying to access a chart in it, that hasn't been stored yet.
Lavacharts
php class (I called it the Volcano object internally because I thought it was clever :laughing:)Lava.js
moduleLava.js
So the reason why in your Vue attempt, the chart is not found, is because your manual inclusion of Lava.js
never had lava.store()
called with a chart, and therefore, cannot find your chart.
Hey @kevinkhill , could you elaborate it more, please? I have the exact same problem while trying your package. What is the right approach to this then?
I'm trying to fetch the Laravel API resource and output it in Vue component.
I haven't abandoned this package, but once my daughter was born, I lost all free time to work on it. 😂
This was the direction I was taking Lavacharts before then, splitting it into a php and js library that worked together or separate.
I have been using Vue a lot more lately, and I really want to make a component/library for lavacharts in vue. I have no promises or timelines, but it is a todo of mine.
What Version?
3.1.11
Issue
I am trying to use it with Laravel and vuejs but I keep getting the error {name: "ChartNotFound", message: "[Lavacharts] Chart with label "Trans" was not found."} However, when I use it directly on the blade file it works. Also I am working on live data and I need the chart to reload every 5 minutes is that possible and are there any extra functions needed?
Controller Code (chart creation code)
View Code
The above does not have an error but if I move the script to vuejs there is an error