Replies: 3 comments 4 replies
-
|
Thanks for starting this! Here are a couple high level ideas I can think of 1) No Custom DSLI think overall for WCC, at least when used by itself, would be to highlight the predictability of following web standards without trying to invent a custom DSL on top of it (a la WebC), but also open to adopting / supporting Community Protocols from the Web Components Community Group It's mostly intended to be used as an implementation detail for Greenwood but having it standalone also provides others to build on top of it, even if just for the DOM / SSR / AST parsing. That said, we do feature WCC prominently on the Greenwood home page, I even promote it as such on the jamstack.org website which leads into my next point... 2) Better JSX SupportOne thing I definitely would like to work on next is improving the JSX support / ergonomics. As we do feature Web Components prominently on the Greenwood home page, I would love to add a tab demonstrating an example using JSX. Our JSX implementation simply compiles down to a standard custom element definition, a la Stencil. Something like we demonstrate in the WCC docs where you can opt-in via a export default class Counter extends HTMLElement {
constructor() {
super();
this.count = 0;
}
connectedCallback() {
this.render(); // this is required
}
increment() {
this.count += 1;
this.render();
}
render() {
const { count } = this;
return (
<div>
<button onclick={this.count -= 1}> -</button>
<span>You have clicked <span class="red">{count}</span> times</span>
<button onclick={this.increment}> +</button>
</div>
);
}
}
customElements.define('wcc-counter', Counter);I think JSX is a great templating language and declaratively authoring your UI is such a nice DX. The JSX support in WCC can be enabled through simply adding a Greenwood plugin. However, as demonstrated above, sometime you do need interactivity, not just static HTML, which leads to my next point... Signals + JSXBuilding off the JSX support, I think implementing the reactivity system around the TC39 Signals proposal, (re) popularized by SolidJS, and now adopted into many frontend frameworks like Svelte, Angular, and Lit. This way, they interoperate with any other Signals based libraries / state management solutions. I think this combo would make a killer sample to put on the Greenwood home page. 🤩 That said, I don't intend for WCC to become a full on frontend library, mostly trying to keep a nice minimal WC SSR system with "good enough" reactivity support, but if you want something more powerful, then I have no problems if you opt to using something like Lit (ideally with Greenwood, hah! 😅 ) WebsiteI would also definitely be open to giving the website a bit of a refresh, too, especially if I can supercharge WCC a bit more in that JSX / Signals department, which I'm hoping to give myself a little time for this fall. Nothing super fancy, but some polish around colors, typography, copy text, etc would be nice. ✨ |
Beta Was this translation helpful? Give feedback.
-
|
Some polish on the WCC site |
Beta Was this translation helpful? Give feedback.
-
|
New website is up at its new domain! 🥳 Thanks for all the help! |
Beta Was this translation helpful? Give feedback.





Uh oh!
There was an error while loading. Please reload this page.
-
Hi guys,
Starting a discussion on a refresh for the WCC page.
Main aim is to position WCC for 2025 and beyond.
What are the most important info/features/capabilities we want to show that can get users from ‘Curious’ to actually ‘Trying it out’ and ‘Sold on it’
Beta Was this translation helpful? Give feedback.
All reactions