diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/babySpawn.ur | 3 | ||||
-rw-r--r-- | tests/dynTable.ur | 8 |
2 files changed, 7 insertions, 4 deletions
diff --git a/tests/babySpawn.ur b/tests/babySpawn.ur new file mode 100644 index 00000000..d43e739f --- /dev/null +++ b/tests/babySpawn.ur @@ -0,0 +1,3 @@ +fun main () : transaction page = return <xml><body> + <button onclick={fn _ => spawn (alert "Hi")}/> +</body></xml> diff --git a/tests/dynTable.ur b/tests/dynTable.ur index 7fe295c6..d73dc52c 100644 --- a/tests/dynTable.ur +++ b/tests/dynTable.ur @@ -8,14 +8,14 @@ fun main () : transaction page = <tr> <td>Hi</td> </tr> </table> - <button onclick={v <- get n; - set n (v + 1); - set s <xml><tr> <td>Whoa!({[v]})</td> </tr></xml>}/> + <button onclick={fn _ => v <- get n; + set n (v + 1); + set s <xml><tr> <td>Whoa!({[v]})</td> </tr></xml>}/> <table> <tr> <dyn signal={signal s1}/> </tr> <tr> <td>Hi!</td> </tr> </table> - <button onclick={set s1 <xml><td>Whoa!</td></xml>}/> + <button onclick={fn _ => set s1 <xml><td>Whoa!</td></xml>}/> </body></xml> |