3 ms·
You can't add interactivity to a static HTML site? Or shift the static pages into modern frameworks?
by epistasis 2y ago
You can't add interactivity to a static HTML site? Or shift the static pages into modern frameworks?
- willsmith72 2y agoI mean let's not go too far and pretend there is 0 advantage to JS
- frostiness 2y agoYou absolutely can, but it's way more common to only know how to create a blank site with a framework than to migrate an existing site. React used to have a section in its documentation for how to add it to your site without adding a build system (not common knowledge, unless it's setting up a blank site through a script) and they've since replaced it with a brief tutorial telling you to migrate your website to a JS module with a link to a suggested build system. All of this matters because the person that has to do this setup might not be you. It's certainly a problem with the frameworks themselves that porting a website (even just to add a little functionality) isn't as easy as setting one up initially but there's not really much an individual can do here. It's one reason I like frameworks like Preact so much, they're actually trying to fix this.
- epistasis 2y agoUnderstood. Makes me think of YAGNI though. https://en.wikipedia.org/wiki/You_aren%27t_gonna_need_it https://en.wikipedia.org/wiki/You_aren%27t_gonna_need_it
- jpc0 2y agoYou mean this: https://react.dev/reference/react-dom/client/createRoot https://react.dev/reference/react-dom/client/createRoot How you bundle react is left as an exercise to the reader but the data is still there?
- no_wizard 2y ago>How you bundle react is left as an exercise to the reader but the data is still there? The Francis Scott Key of web development "...and the data was still there!"
- amelius 2y agoNo because a page-load e.g. breaks the animations.
- epistasis 2y agoAre these frameworks incapable of having the static content as something that can be served? Are the links in the existing content unable to be updated to whatever need to happen for the page transitions?
- WorldMaker 2y agoCSS does support page change transitions now.
- deleted 2y ago[deleted]