tradingview / charting-library-examples

Examples of Charting Library integrations with other libraries, frameworks and data transports
MIT License
1.44k stars 768 forks source link

why do we need the charting library folder both in public and in src? #397

Open orelhindi-abra opened 1 month ago

orelhindi-abra commented 1 month ago

Checklist

Describe the bug According to the documentation, the charting library folder needs to be placed in both the src and public directories. I would like to understand the reasoning behind this requirement. Moreover, the datafeeds library which we need to use like so in the index.html file: <script src="./datafeeds/udf/dist/bundle.js"></script> is there way to use datafeed without using it directly in the html file? because if its not provided we get the following error: react-dom_client.js?v=54d56a3b:9127 Uncaught TypeError: Cannot read properties of undefined (reading 'UDFCompatibleDatafeed')

I'm currently trying to build a package from this project and need guidance on the best approach for handling this setup during the build process. Is there a recommended way to manage the charting library when packaging the project to avoid duplication in both folders?

Thank you for your help!

A clear and concise description of what the bug is.

Expected behavior

To only use the charting library folder once.

orelhindi-abra commented 1 month ago

any?