Re:FicusJS
by Sn0wCoder on Sunday March 28, 2021 @07:56PM
(#26616101)
- Great question. The main thing I was looking for was going build-less and the section of Ficus docs kinda sold me on the idea. Seems we still need to use a dev-server to allow native imports like
Thanks for helping me understand my own decision.
[ Parent
| on HN ]
I work on LitElement and if you want to use it buildless you can do so with the JavaScript reactive properties API (so you don't need TypeScript or Babel decorators to declare properties) and Chrome 89's support for import maps.
Generally, I think an import specifier rewriting dev server like Web Dev Server is the way to go since it'll work with so many other libraries out there.
How lightweight is Web Dev Server? Back when the official way to go was still polyserve, I've had to make this:
https://github.com/unrelentingtech/es-module-devserver
which is a tiny middleware that uses regexps to accomplish the task instead of dragging in a JS parser :)
Thanks, will give it try.
I don't think you'll ever get away without a build chain using LitElement. If you are, I think your project is a toy, hobby, or very far from complete
I have been using lit-html for years now, and lit-element for a couple years all in vanilla js for evergreen browsers with the only build step being bundling for production. Here is one of the projects: https://cisterna.app
Re:FicusJS
by claytongulick on Sunday March 28, 2021 @08:58PM
(#26616569)
You may want to take a look at lit-html coupled with ApplicationState [1] (disclaimer, I'm the author of ApplicationState)
How does ApplicationState compare to e.g. https://immerjs.github.io/immer ?