A question that has happened to me is that different Data type in javascript how many use of memory . for Example in C++ data type like int , char , float uses order 2 , 1 ,
As of today, MDN Data Structures page gives some more info about it:
According to the ECMAScript standard, there is only one number type: the double-precision 64-bit binary format IEEE 754 value
So that should amount to 8 bytes.
JavaScript's String type is used to represent textual data. It is a set of "elements" of 16-bit unsigned integer values.
So that should amount to 2 bytes per character.
Boolean represents a logical entity and can have two values: true, and false.
Nothing more about that.