Closed patrickarlt closed 3 years ago
The scope of calcite-components is absolutely intended to include marketing sites and documentation sites like Esri.com / ArcGIS for Developer documentation.
We should use our support channels with Ionic / Stencil to get more definitive direction for these issues, which will be understandably be show stoppers for some groups until they are resolved.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This issue has been automatically closed due to inactivity.
We have been successfully using Calcite Component in a lot of our work on ArcGIS for Developers. However our main blocker remains the fact that there will always be a FOUC with Calcite Component because the JS and CSS are bundled together and the CSS won't apply until the JavaScript renders leaving items in slots unstyled. This was particularly noticeable on
<calcite-tree>
https://github.com/Esri/calcite-components/issues/609 in cases where we had ~3000+ items like the ArcGIS Enterprise SDK API Ref often taking several seconds to parse and initialize.Here is a smaller example from the Enterrpise SDK Guide (~100) items:
We eventually re-wrote a sub-set of
<calcite-tree>
in React to avoid this and maintain more control over rendering and performance which is what you see on the site now.Stencil does support pre-rendering via hydrate app which I setup for Calcite Components. I then wrote a Gatsby JS plugin for calcite component prerendering . This worked but had a few issues:
In the end I think it would help to define what the scope of Calcite Components is and how it should be used. Our use cases on ArcGIS for Developers require everything to be prerendered for SEO we want to avoid a FOUC and thus can't wait for Calcite Components to load and style everything. I'm sure esri.com has similar issues. This has lead us to limiting Calcite Component use to things like
<calcite-dropdown>
,<calcite-tooltip>
<calcite-modal>
and<calcite-popover>
which can hide under other pre-rendered elements.Ideally we could:
<calcite-tree>
is a big one for us but we could also use others.