1. Consolidation. There will be fewer and more powerful tech companies in the future and they will grow and profit as they shrink their headcount. The belief that profits and growth = jobs will soon be recognized as twentieth century thinking.
2. Automation. Spiffy tools, reuse, AI...no matter how you slice it, your skills are getting pushed into the shared stack every day.
3. Internationalization. You might be surprised to find out that there are React coders in South America that have all the right tats and piercings, read HN and Blind, bang on leetcode...and will work for 1/5 what you will.
The only question is how many people leaving tech presently will never be able to get back in, or maybe they just realize driving a Fedex truck for the same money is less stressful.
Also don't be too spooked by layoffs so far, its just beginning in tech and finance and this wave still hasn't hit the huge cohort of permanently cashflow-negative startups somehow still clinging to life...they will ALL be gone.