It's really not the "electronics" fault.
There are industries that can build and spec control boards that WILL get you a minimum of 10yrs of service or more, and consistently.
Examples:
Smoke/CO alarm industry (of which I was part of), will build and spec electronic parts with life and cycle times to meet the minimum 10yr warranty period.
we put warnings on all the devices saying that they must be replaced every 10yrs.
That's NOT because the electronics cannot last longer. They often can. It's just that, failures before that are statistically very low. And failures after 10yrs statistically go up, from sheer age of components. But, many control boards and parts DO last longer than the spec'd 10yrs. But the nature of those being a life safety device, it's imperative we put that warning on.
Automotive electronics are extremely robust. Sure there are problems were certain things might fail, but those are in the statistical realm of being outliers. The vast majority of those electronic parts are designed and built to withstand years of service in very very abusive conditions.
They must withstand repeated power cycles on and off, happening in extreme heat and cold, for years in and out. And a vast majority of them do that.
Some fail, because theses are parts built by humans, installed by humans. The intent is to have them last, but some might be faulty. It just happens.
Military electronics are extremely robust and will last virtually forever. They also have costs in the stratosphere, which governments only pay. But the necesity is to have zero field failures. And getting there is very expensive.
The appliance electronics are now (within the last several years) purposely built very cheap. With terrible construction at times, sloppy soldering or conformal coatings. Lowest bidder relays or components.
Much of this is driven by the constant pressure to keep appliance prices rock bottom.
It's a complex dance between OEM company, retailers, and customers alike.
The OEM wants the highest margin and profit. The retailer wants the highest turnover and highest margin. And the customer wants the lowest price.
These incentives are all diametrically opposed from eachother.
If appliance price and BOM costs and quality were to stay constant to today, coming out of the 80s, appliance prices would be at least $1,000 for a BOL machine. Heck, maybe they should be.
The OEMs are terrified of adding too much cost (quality) to the machines because the retailers won't put up with it, and they are hell bent on selling a washer to customers in the $500-700 range. That's not far off from the sales price in the late 80s and 90s for many machines. There's been tremendous inflation since then, and that cost/profit must be squeezed from somewhere. So they took it out of the steel, out of the components, went offshore for lots of stuff etc.
BensApplianceandJunk has spoke to this at many instances. And it has a lot of validity.
The unfortunate cynical timeline we're in however is, if the OEMs and retailers were to provide $1,000 -$2,000 machines to be on price parity of machines from the "Imperial" time period, they probably would not add much quality back in. They would just keep those added profits and pump them into stock buybacks.
Unfortunately further, with the erosion of purchasing power and the winds the economy is going into, appliance prices will probably stay the same or even go UP, while quality further errodes until there's a full revolt from customers/retailers. And we're not at that bottom yet.