Closed leroydev closed 6 months ago
Hi @leroydev , thank you very much for deep dive into code and propose optimization!
However, adapter is designed to be a global config. Just like you need to config global providers for redux, some UI libs, etc. So using nice form consists of two parts, one for config and the other is real usage.
Hi @supnate, thanks for taking the time to review quickly! What do you think about adding a comment above the example code that adds the adapters, that mentions this should only be done globally but is done within the example to make them self-contained? Then you have the best of both worlds, users can more quickly setup an example locally to play around with it and it is clear to them that the adapters is supposed to be global configuration.
If not, I do feel that including the definition of the custom datepicker in each example does add value. Otherwise the user will be searching for a bit and would have to run into the one example that does have that code in it.
And the lazy loading should make the docs faster to load so might also be an improvement you want to consider.
Let me know which parts you want in what form and I'll make adjustments 🙂
Thanks @leroydev .
Closed in favor of #6
Closes #4. Also makes all the examples lazy loaded. This should speed up first load speed of the examples website but should be tested whether this works properly in a production build too. Locally for me with a production build served with http-server it did work.