Update blink1.js

Improve existing typechecking, add additional typechecking.  Still needs typechecking for the `on` and `position` parameters.

See #5.