Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> JavaScript allows for objects to be left in an inconsistent state right after being created, as their properties don’t need to be initialised.

No, you just forgot to put `this` in front of `width` and `height`. (Arguments do default to `undefined`, though.)



Consider applying for YC's Winter 2027 batch! Applications are open till November 2.

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

Search: