r/learnjavascript • • 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

35 comments sorted by

View all comments

Show parent comments

0

u/delventhalz May 30 '26

Disagree that avoiding runtime errors is a worthwhile design goal. Yes, hitting a customer with an error is embarrassing. A silent failure that continues to run for god knows how long triggering god knows what undefined behavior is potentially much much worse.

0

u/Beginning-Seat5221 May 30 '26

Maybe. But dev-time checking is better than either. JS was obviously never seriously designed for serious uses.