2 ms·
javascript is way worse in cleanliness. PHP has the advantage of having been able to break backwards compat and fix some of its worst messes, even down to some
by asddubs 3y ago
javascript is way worse in cleanliness. PHP has the advantage of having been able to break backwards compat and fix some of its worst messes, even down to some questionable soft equalities. Also PHP nicely sidesteps the string addition/concatenation problem by having a dedicated operator for concatenation.
- zebomon 3y agoFair enough!
- kijin 3y agoEven better, you don't even need to worry about those backward compatibility breaks if you wrote relatively clean, warning-free code in the first place. Only the very worst parts of PHP's legacy have been thrown out, and only after multiple years of deprecation notices. They've also been following semver quite strictly since 5.3, so you know exactly when to expect breaking changes. Compared to the Python 2 to 3 mess and the constant churn that today's frontend frameworks seem to suffer from, I would say that PHP is more serious about maintaining backward compatibility than nearly every other language commonly used in web dev.