<script> tag. Both methods have their unique advantages and usage scenarios.
Modern front-end development often uses as a module downloaded from npm due to the convenience it offers in managing project dependencies. If you’re building a large-scale application with many dependencies, npm might be the way to go.
However, it’s essential not to ignore the advantages of a CDN, it can significantly improve application load times and help giving quick hotfix, which can be particularly beneficial for smaller projects or quick prototypes.
On the other hand, using a CDN involves embedding a
Additionally, if the user has already visited a site that uses the same CDN, like jQuery for example, the file might already be cached in their browser, further improving load times.
Remember to always consult the library or SDK’s documentation for specific instructions on how to include it in your project, as the process can vary slightly depending on the package.
Both methods are fully supported and documented at SuperViz, and the choice between the two depends largely on your project needs and structure. Whether you’re building a complex application with numerous dependencies or a simple prototype, SuperViz’s can suit you with CND or a npm package.
If you are interested in finding detailed instructions on how to use our SDK as a CDN, like the technical differences from using it as a package, check our documentation page for this case before using SuperViz.