js-runtime/example.html
2023-09-09 13:46:41 +02:00

13 lines
216 B
HTML

<script src="runtime-checker.js"></script>
<script>
const sum = typedFunction((a_number, b_number) => {
return a + b;
});
const result = sum(1, 2);
console.log(result); // 3
sum("1", 2); // Error
</script>