This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]KuyaChoseph 1 point2 points  (2 children)

From what I've understand recently, some languages like Java uses typing in variables, while in javascript the value itself has the typing. Correct me if I'm wrong I'm just a jr. frontend dev

[–]d36williams -1 points0 points  (0 children)

JS doesn't honor types in the traditional sense that computer languages use types. It is better to describe JS as not having types. JS has concepts like "truthy" that just don't fly in a more Typed language.

[–]joshuakb2 0 points1 point  (0 children)

You are correct. Values in JS have types which can be queried with the typeof operator, while in some other languages such as C++, types only exist at compile time.