3 ms·
Background knowledge and first principles also come in handy with more mundane work. Arguably our most prominent contribution to OSS (outside of our own projec
by sheetjs 8y ago
Background knowledge and first principles also come in handy with more mundane work.
Arguably our most prominent contribution to OSS (outside of our own projects) was in React. We're credited in the codebase when the approach was used: https://github.com/facebook/react/blob/v16.0.0/src/renderers/shared/utils/adler32.js#L17 https://github.com/facebook/react/blob/v16.0.0/src/renderers...
As discussed in the original PR https://github.com/facebook/react/pull/4400 https://github.com/facebook/react/pull/4400 the original checksum used a naive adler-32 algorithm, but with some basic math you can find a much more efficient implementation that eliminates most of the mod operations without risking a hidden deoptimizing overflow.
It's not everyday that you get to use your background knowledge, but when you do it feels great!