Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Show HN: Use TypeScript in Servo Browser Fork (github.com/pannous)
1 point by singularity2001 5 days ago | hide | past | favorite | discuss
Wasm exports are immediately available to TypeScript, even gc objects!

``` <script type="text/wast"> (module (type $Box (struct (field $val (mut i32)))) (global $box (export "box") (ref $Box) (struct.new $Box (i32.const 42))) ) </script> <script type="text/typescript"> const greeting: string = "Hello from TypeScript and Wasm!"; console.log(greeting, box.val); </script>





Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: