Mistakes will be made and it is better the compiler/interpreter catches them early before they turn into problems. Enabling any strict modes will force you to write better code, e.g.:
For Javascript, "use strict"; should be at the start of all the programs. It forces a stricter subset of JavaScript which helps make programs more secure with less chance chance of errors.
In Perl use strict; use warnings;. Like above, it will help flag more potential problems and help make your program more secure and maintainable by catching mistakes.
In FreePascal {$J-}{$R+}. Enables constants being constant(!) and range checking.
The D Programming Language is fairly strict by default, by putting @safe where possible, it will enable additional protections to help make sure your program is memory safe.
Many other compilers have switches to enable more thorough checking too. It may be worth looking at using a language that forces strictness by default such as C#, Go or Rust.
Updated
(31/08/2023)