FB has thousands of employees who write code. I highly doubt many of them are writing sorting algos from scratch. They should know which sorting solves the problem and use an appropriate library.
The same applies to most other low level problems. They should understand the problem and the best practice to solve it. In most cases writing low level solutions from scratch is not the best practice.
FB is a mature company now with a slowed growth rate. They've been dealing with scale and performance for long enough now that it shouldn't be necessary to write all of these things from scratch.
Facebook has pioneered multiple languages and programming API packages. I'm certain they have had to implement library functions "from scratch" multiple times.
I can assure you that the growth rate has not slowed. Do not use the USA as a proxy for global behaviors.
The same applies to most other low level problems. They should understand the problem and the best practice to solve it. In most cases writing low level solutions from scratch is not the best practice.
FB is a mature company now with a slowed growth rate. They've been dealing with scale and performance for long enough now that it shouldn't be necessary to write all of these things from scratch.