+ 3
What is JavaScript with(o)?
I saw use of a keyword with taking one param in a function, but even documentation on it seems kinda hard to understand. It seems to change scope of an existing variable? Anyone want to give a better explanation?
10 ответов
+ 7
oh the with statement its a bad thing dont try using it,it digs into an object for its properties.its deprecated.
es6 introduces object destructuring for that.
const {PI}=Math;
+ 6
obsolete feature, don't use it, like eval
+ 4
i dont understand your question.illd like to help
+ 2
with statement was born for make access to complex/long variable (lexically) in easy way but now its deprecated because add more problems than it remove... Dont use it at all
+ 1
KrOW it looks like it acts like c++’s using when it comes to the JavaScript Math library, but I don’t completely see what it’s doing with the two param function
+ 1
you need explore more
0
Brains🇳🇬 ooo I’ll look into that!
0
JavaScript software company IT PROGRAMMNG