One of the most expensive components of your computer is your monitor, but it is also one of the most standardized and longest-lasting. Think about it: pretty much any monitor bought in the last 20+ years* (including CRTs) can be used with any computer or video card on the market, requiring at most a super cheap adapter.
But with an AIO, you lose this major advatage desktop systems have over laptops. You're still paying for the monitor, but have little to no choice in which model it will be, and you will only ever use it with this one computer. And when the computer dies, the monitor is finished too (even if it's in working condition).
The monitor is one of the cheaper components these days. Yes, this is a 27" 4K IPS monitor. It probably cost $2K last year. Nowadays they can be hand under $1k. And in a few years when the computer dies, you probably can buy it for $200.
Monitors, especially flat screens were pricey 20 years ago because everyone used CRTs. Now that everyone uses LCDs, the cost of the technology has plummeted dramatically, especially at resolutions that re-use TV components. Mass production basically plunged the prices. It was only a decade ago when a 17" LCD was a luxury, and nowadays you can't give them away.
Everyone complains about 1080p or 4K, but using TV resolutions mean mass production takes the cost way way way down.
And given the prevalence of 27" monitors of late, the price of them will plummet soon as well and those with 24" monitors soon can't give them away.
By the time this computer is dead, the monitor will probably be fairly worthless because you can run out and pick up a brand new one with all sorts of improvements. Scavenging is good for now, but after that it'll be a hobby project.