feat(site): update content

This commit is contained in:
Ayo 2023-11-27 09:46:57 +01:00
parent 3e8334f2c1
commit c9dd590931
2 changed files with 4 additions and 3 deletions

View file

@ -29,7 +29,7 @@
<p> <p>
By extending our base class, you get an easy authoring experience as you would expect in writing your components:</p> By extending our base class, you get an easy authoring experience as you would expect in writing your components:</p>
<ul> <ul>
<li>A signals-like <code-block inline>props</code-block> API that synchronizes your components' property values and UI</li> <li>A <code-block inline>props</code-block> API that synchronizes your components' property values and HTML attributes</li>
<li>Sensible life-cycle hooks that you understand and remember</li> <li>Sensible life-cycle hooks that you understand and remember</li>
<li>Extensible templates & renderer (examples in-progress)</li> <li>Extensible templates & renderer (examples in-progress)</li>
<li>Provided out-of-the-box with <a href="https://ayco.io/gh/McFly">McFly</a>, a powerful no-framework framework</li> <li>Provided out-of-the-box with <a href="https://ayco.io/gh/McFly">McFly</a>, a powerful no-framework framework</li>

View file

@ -5,10 +5,11 @@ export class Counter extends WebComponent {
static properties = ["count"]; static properties = ["count"];
onInit() { onInit() {
this.props.count = 1; this.props.count = 1;
let i = 1
this.onclick = ()=> ++this.props.count this.onclick = ()=> ++this.props.count
let double = () => this.props.count * 2; let double = () => i * 2;
console.log(double()); console.log(double());
this.props.count = 3; i = 3;
console.log(double()); console.log(double());
} }
get template() { get template() {