DEV Community

[Comment from a deleted post]
Collapse
 
devoresyah profile image
DeVoresyah ArEst

finally, someone prefers js than typescript. I already use javascript since I was in elementary school. And the reason why I love js and still using it until now is that js didn't need many things/rules/whatever like typescript. I mean I can even use the variable without declaring it.

and Idk why nowadays, many people move to typescript. Like Adonis 5 migrating to typescript T_T

Collapse
 
abdelrahman_hussein profile image
AbdelRahman Hussein Mahmoud

yeah, js have a lot of flexibility, but watch out while using a variable without declaring, it is not a good approach and will be in a global scope and that is why there is 'use strict'.

Collapse
 
devoresyah profile image
DeVoresyah ArEst

yes I know, just want to tell to everyone that js didn't strict as default, not like Java or PHP that will error if you forget to put ; at the end of the line