luwes / wesc

We are the Superlative Components!
https://wesc-nextjs.vercel.app
21 stars 0 forks source link

feat: add Rust WeSC HTML component bundler #23

Closed luwes closed 6 months ago

luwes commented 6 months ago

Adds a streaming custom element bundler written in Rust using the lol-html parser.

This is my first Rust project so this code is probably pretty bad, feedback very welcome!

The idea is to create a single-file HTML component format and builder that builds the HTML result super fast (streaming, low memory) and is server language agnostic.

TODO: The JS (and CSS) in the top level script and style tag are bundled up separately can be output as JS and CSS files.

The HTML (template) for the client components doesn't have to be added to the JS bundle which give huge savings compared to how most JS frameworks need the templates for hydration.

Update, released a first version: https://crates.io/crates/wesc

vercel[bot] commented 6 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
wesc-astro ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 18, 2024 0:59am
wesc-nextjs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 18, 2024 0:59am
wesc-sveltekit ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 18, 2024 0:59am
netlify[bot] commented 6 months ago

Deploy Preview for wesc-eleventy canceled.

Name Link
Latest commit 92e9434fa54ebf33c6caea7a315438bb86ea0477
Latest deploy log https://app.netlify.com/sites/wesc-eleventy/deploys/65f791a97a0e890008d7224a
netlify[bot] commented 6 months ago

Deploy Preview for wesc-node canceled.

Name Link
Latest commit 92e9434fa54ebf33c6caea7a315438bb86ea0477
Latest deploy log https://app.netlify.com/sites/wesc-node/deploys/65f791a95c475600084a4bd1
netlify[bot] commented 6 months ago

Deploy Preview for wesc-remixrun canceled.

Name Link
Latest commit 92e9434fa54ebf33c6caea7a315438bb86ea0477
Latest deploy log https://app.netlify.com/sites/wesc-remixrun/deploys/65f791a99431380008418778
cloudflare-pages[bot] commented 6 months ago

Deploying wesc with  Cloudflare Pages  Cloudflare Pages

Latest commit: 92e9434
Status: ✅  Deploy successful!
Preview URL: https://1c63e325.wesc-coe.pages.dev
Branch Preview URL: https://wesc-rust.wesc-coe.pages.dev

View logs