-
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Solid: match and If statements support
- Loading branch information
Showing
5 changed files
with
43 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 9 additions & 5 deletions
14
tests/Oxpecker.Solid.Tests/Cases/Parameters/Parameters.expected
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,17 @@ | ||
import { int32ToString } from "./fable_modules/fable-library-js.4.23.0/Util.js"; | ||
|
||
export function Test(id) { | ||
export function Test(id, hello) { | ||
const helloWorld = hello + " world"; | ||
return <div id={int32ToString(id)} | ||
class="testclass" | ||
aria-labelledby="testlabel"> | ||
<> | ||
Hello | ||
</> | ||
world! | ||
{(id > 0) ? <h3></h3> : <h2 class={int32ToString(id)}> | ||
{id} | ||
</h2>} | ||
{(id > 5) ? <h4 class={helloWorld}></h4> : helloWorld} | ||
{(id === 2) ? <h1 id="two"> | ||
{helloWorld} | ||
</h1> : ((id > 2) ? <h1 id={int32ToString(id)}></h1> : <h1></h1>)} | ||
</div>; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters