tvjsx / trading-vue-js

💹 Hackable charting lib for traders. You can draw literally ANYTHING on top of candlestick charts. [Not Maintained]
https://tvjsx.github.io/trading-vue-demo/
MIT License
2.09k stars 637 forks source link

can we use this in react ? or does react has similar library like this ? #205

Closed eminvergil closed 3 years ago

eminvergil commented 3 years ago

Can we use this in react ? or does react has similar library like this ? If there is no library like this in react i think we should start an open source project.

C451 commented 3 years ago

There is no similar project AFAIK. Please feel free to start, but I must say that the lib has a lot of vue-specific tricks.

NorthMcCormick commented 3 years ago

I have never used Vue (I use Stencil and other web tech, though) and have been trying to find this exact kind of lib.

My first searches say no... Can anyone shed light on if I can run these charts inside web components? It's worth asking!

Anyways, awesome lib :)

JohannesHoppe commented 3 years ago

You can export the chart as a custom element. See: https://github.com/karol-f/vue-custom-element Then you can embed your custom element anywhere! 😃

NorthMcCormick commented 3 years ago

@JohannesHoppe Thank you for the resource. I am going to give this a shot. This will be my first time ever working in Vue. If anyone has experience and wants to throw together a working example before I can please do 😁

Edit: I've made some progress. I've got a basic wrapper setup for a custom component. https://github.com/NorthMcCormick/trading-vue-js-Web-Component-Example

JohannesHoppe commented 3 years ago

First time Vue here, too! 😆

Great progress so far. I did something very similar on top of a plain Vue CLI project. In my version you can use properties to hand over data, too. I could prepare another demo in some hours, if you are still interested?

JohannesHoppe commented 3 years ago

@NorthMcCormick Check out this demo. This should provide you with everything you need. Have fun with it! 😃

Source: https://github.com/JohannesHoppe/trading-vue-js-web-component-example

Demo: https://johanneshoppe.github.io/trading-vue-js-web-component-example/