Skip to content

Commit

Permalink
Feedback: no space before method parens, no TS, else-if, ColorSelect …
Browse files Browse the repository at this point in the history
…works now
  • Loading branch information
tigt committed Jan 18, 2023
1 parent a245195 commit 8e17907
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 38 deletions.
24 changes: 12 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/svelte.svg" />
<b>Svelte</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/100" /></summary>
<img alt="100% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/100" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -52,7 +52,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/react.svg" />
<b>React</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/100" /></summary>
<img alt="100% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/100" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -89,7 +89,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/vue.svg" />
<b>Vue 3</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/96" /></summary>
<img alt="96% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/96" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -126,7 +126,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/solid.svg" />
<b>SolidJS</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>
<img alt="92% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -163,7 +163,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/qwik.svg" />
<b>Qwik</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>
<img alt="92% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -200,7 +200,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/angular.svg" />
<b>Angular</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>
<img alt="92% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -237,7 +237,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/lit.svg" />
<b>Lit</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/96" /></summary>
<img alt="96% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/96" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -274,7 +274,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/vue.svg" />
<b>Vue 2</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/96" /></summary>
<img alt="96% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/96" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -311,7 +311,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/ember.svg" />
<b>Ember</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>
<img alt="92% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -348,7 +348,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/alpine.svg" />
<b>Alpine</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/96" /></summary>
<img alt="96% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/96" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -385,7 +385,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/aurelia.svg" />
<b>Aurelia 1</b>
<img src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>
<img alt="92% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92" /></summary>

- [x] Reactivity
- [x] Declare state
Expand Down Expand Up @@ -422,7 +422,7 @@ How do we solve this ? Developers love having framework overview by examples. It
<summary>
<img width="18" height="18" src="public/framework/marko.svg">
<b>Marko</b>
<img alt="92% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/92"></summary>
<img alt="93% progress" src="https://us-central1-progress-markdown.cloudfunctions.net/progress/93"></summary>

- [x] Reactivity
- [x] Declare state
Expand Down
10 changes: 5 additions & 5 deletions content/2-templating/6-conditional/marko/TrafficLight.marko
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ static const TRAFFIC_LIGHTS = ["red", "orange", "green"];
<let/lightIndex = 0/>
<const/light = TRAFFIC_LIGHTS[lightIndex]/>

<button onClick () {
lightIndex = (lightIndex + 1) % TRAFFIC_LIGHTS.length;
}>Next light</button>
<button onClick() { lightIndex = (lightIndex + 1) % TRAFFIC_LIGHTS.length }>
Next light
</button>
<p>Light is: ${light}</p>
<p>
You must
<if=light === "red">STOP</if>
<if=light === "orange">SLOW DOWN</if>
<if=light === "green">GO</if>
<else-if=light === "orange">SLOW DOWN</if>
<else>GO</if>
</p>
4 changes: 2 additions & 2 deletions content/3-lifecycle/2-on-unmount/marko/Time.marko
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<let/time = new Date()/>
<lifecycle
onMount () { this.timer = setInterval(_ => time = new Date(), 1000) }
onDestroy () { clearInterval(this.timer) }
onMount() { this.timer = setInterval(_ => time = new Date(), 1000) }
onDestroy() { clearInterval(this.timer) }
/>
<p>Current time: ${time.toLocaleTimeString()}</p>
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
export interface Input {
name: string;
age: number | void;
favouriteColors: string[];
isAvailable: boolean;
}

<const/{
name = "",
age = null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,2 @@
export interface Input {
onYes: function;
onNo: function;
}

<button onClick=input.onYes>YES</button>
<button onClick=input.onNo>NO</button>
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<let/isHappy = true/>
<p>Are you happy?</p>
<AnswerButton
onYes () { isHappy = true }
onNo () { isHappy = false }
onYes() { isHappy = true }
onNo() { isHappy = false }
/>
<p style={ fontSize: 50 }>${isHappy ? "😀" : "😥"}</p>
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<h2>My Profile</h2>
<p>Username: ${username}</p>
<p>Email: ${email}</p>
<button onClick () { updateUsername("Jane") }>
<button onClick() { updateUsername("Jane") }>
Update username to Jane
</button>
</div>
8 changes: 4 additions & 4 deletions content/6-form-input/4-select/marko/ColorSelect.marko
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<let/colors = [
static const colors = [
{ id: 1, text: "red" },
{ id: 2, text: "blue" },
{ id: 3, text: "green" },
{ id: 4, text: "gray", isDisabled: true },
]/>
];
<let/selectedColorId = 2/>

<select onChange (event) { selectedColorId = event.target.value }>
<select onChange(event) { selectedColorId = event.target.value }>
<for|{ id, isDisabled, text }| of=colors>
<option value=id disabled=isDisabled checked=id === selectedColorId>
<option value=id disabled=isDisabled selected=id === selectedColorId>
${text}
</option>
</for>
Expand Down

0 comments on commit 8e17907

Please sign in to comment.