Make PgnViewerJS easy to use in different environments - #187
Conversation
Universal Module Definition is a way of building javascript library. After this change it will be available from global variable, requirejs, commonjs and es6 module.
|
Thank you a lot for providing the pull request! I have looked at you commits, and I will check them. In my opinion, the first and third ones are easy, and I would like to include them anyway. The second one is critical (in my opinion) because it will change the size of the file a lot. I have done a different approach (and I am not completely glad with it), but it has some advantages. The files contained in the asset folder are not used by most people most of the time. So downloading them all them time, for the 1% usage of 1% of people is not the best solution, in my opinion. Therefore, could you split the pull request into 2, and have the second (Bundle assets...) separated? |
|
So I will give it a try and check the result. What is to be checked:
So perhaps there will be adjustments to your PR, but hopefully it will work. Before doing the next release, I have to check the questions above. Thank you a lot for providing your pull request! |
Allow to use pgn-viewer with other import methods
Universal Module Definition is a way of building javascript library.
After this change it will be available from global variable, requirejs,
commonjs and es6 module.
Add example for ReactJS
Related: #162