You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm wondering if, for pages where the DOM only needs to be modified once and not updated multiple times, if a lightweight HTML implementation that just makes use of e.g. createElement and no other dependencies except Web.DOM (I think), would make sense?
Maybe there aren't many people writing such static displays - but as someone writing a widget intended to be integrated into 3rd party websites, the idea is appealing. With closure compiler I have my app size down to about 300K, but this could probably take it down further.
I guess the types of DOM functions might have to be specialized somewhat to always return forall a. Widget HTML a, since the widgets are static, they can never end and return a value.
The text was updated successfully, but these errors were encountered:
It does make sense, and I've thought about doing something similar for say server side rendering.
You can currently perform server side rendering by simply discharging the widget once and getting a view, and then throwing the rest of the widget away. But on the server, having to load the entire React library is probably overkill.
I guess this fits in with the other issue (#14) about abstracting the DOM methods to allow putting in alternative backend implementations. Should we close this issue here and continue the discussion in that issue?
I'm wondering if, for pages where the DOM only needs to be modified once and not updated multiple times, if a lightweight HTML implementation that just makes use of e.g.
createElement
and no other dependencies exceptWeb.DOM
(I think), would make sense?Maybe there aren't many people writing such static displays - but as someone writing a widget intended to be integrated into 3rd party websites, the idea is appealing. With closure compiler I have my app size down to about 300K, but this could probably take it down further.
I guess the types of DOM functions might have to be specialized somewhat to always return
forall a. Widget HTML a
, since the widgets are static, they can never end and return a value.The text was updated successfully, but these errors were encountered: