3 ms·
It's not really about standard compliance, it's more an issue of how the browser behaves in non-standard situations and other fun edge cases. If devs only test
by dmm 10y ago
It's not really about standard compliance, it's more an issue of how the browser behaves in non-standard situations and other fun edge cases. If devs only test with chrome then it's very easy to become dependent on behavior specific to chrome.
For example, yesterday I was implementing a server that uses http multipart to stream images to a browser. multipart uses two methods to frame messages: a length prefix and a boundary token. So when you send a message you prefix it with something like
Content-Type: image/jpeg
Content-Length: 12345
And you end it with something like
--MagicArbitraryBoundaryTokenPreviouslySpecifiedInHead
In principle these are redundant, you could frame the content with either one but both are provided. And that's where the problem started. I misspelled a property name and because I'm using javascript it helpfully inserted 'undefined' in the "Content-Length" header. Firefox refused to display the images but chrome happily displayed them as if there were no problem.
If I had only tested in chrome I probably wouldn't have noticed that my code had a problem that was breaking other browsers.