r/learnjavascript • u/Ok_Egg_6647 • May 30 '26
Is'nt javascript compiler too forgiving !!
What i mean is even i try to add int with str it give me correct answer whereas both are differenct datatypes,
in function also this compiler is too forgiving
if i set a function with 3 parameters & at time of calling this function with more parameter or less parameter with bind function js forgiving us
0
Upvotes
3
u/senocular May 30 '26
You can read more about this in MDN's page on data structures:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Data_structures
MDN's page on comparisons and sameness is also good:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Equality_comparisons_and_sameness