Currently, I am in the process of creating a TypeScript library.
As part of this project, I have incorporated the https://github.com/Simonwep/pickr library.
My goal is to make the library easily accessible for users, but I am uncertain about whether I should bundle the pickr library or simply include a reference in the package.json file.
Upon testing the library in a sample project, everything functions correctly in development mode as it loads from node_modules. However, when I attempt to build the project and load it, there are loading failures unless I explicitly import the library using:
<script src="https://cdn.jsdelivr.net/npm/@simonwep/pickr/dist/pickr.min.js"></script>
If the library will be utilized in a web browser, I have configured it so that the script tag is automatically included.
However, what if someone chooses to use the library within an ionic project designed for a tablet device?
In such a scenario, the Pickr library must be bundled with the final build.
Is this bundling process automated? What would be the proper approach to integrating a third-party library under these circumstances?