|Here;s my thoughts, as a tech author.
I'm currently working on a hard copy, print published book for Packt, so there are obviously books still being sold in enough volume that the publishers are still confident getting authors on board to write content.
However, MOST of the content I actually get paid to write comes in one of two forms.
1) Very short, quick learning books, typically only released as eBooks, that I get paid a one off for and the company hiring me get to keep all copyrights. These books typically are used for pure marketing purposes, and are often given away free. The daily build news letter from CP, often has a few linked in it. The purpose of these books is simple. For the reader, they are quick to consume, quick to learn from, and in the case of some publishers (That don't cater to developers, but to CEO's, CTO's etc) they are designed to get non techs to a level where they at least sort of understand what the techs are on about.
2) Paid blogging. Pure and simple. Most of the sites I blog for are media outlets, they make thier money from advertising, but people won't come to view the adverts unles there is suitable content for them to visit the site. An awfull lot of these sites, are happy to go for the lowest common denomitator they can, and often pick up citizen developers at half the price folks like me charge, who then write content that's only just enough plausible to look as though it's true fact.
For the "in print" books, I typically don't get paid, well not in the "truest sense", that is I don't get X amount per hour for writing Y, typically the publisher will make a guess at how many thier going to sell, and give me a slice of those royaties up front.
What then happens is I get none of the royalties from the sales until that amount exceeds what I was given upfront.
So, if I get say £5000 (Yes I'm in the UK... deal with it ), but the book never makes any more than £2000 it sales, then I come out on top.
If I get £5000, and the book makes £10000, the I'll see another £5000.
Note that I picked those figures out the air, it's not typically a fixed portion of successive royalties, it's typically a single fixed pre payment, then a given percentage after that.
So I might make £5000 up front, but on £10k worth of sales the % might be lower and I might make only £2k, things are often stacked in favour of the publishing house for in print books.
So what's my actual point.
Many tech authors don't do in print titles any more simply beacuse it's not worth thier while, The book I'm on with will only net me some nice income if it sells in excess of about 30,000 copies.
Since it's a .NET core 3 title, I and the publisher do expect it to sell quite a lot, as where hoping to release when DNC3 goes first public release.
In general though, writing in print books really doesn't bring in a huge amount these days, unless (as has beenpointed out) you have what's called a perpetual title, that continues to sell in absence of any particular technology or platform.
The money is to be made in short marketing focused titles and paid blogging, but beacuse of the lack of a royalty scheme with these titles, you generally have to spend more hours writing if you want to use it to provide a full time income.
Hopefully this has given you guys a little bit of an insight into the current state of the market from a writers point of view.