It doesn't have to be thrown out. It can be re-used by someone else. Just build durable electronics. It will last a decade easily. Upgradeable laptops are actually less sustainable: people buy not 1 or 2 laptops, but 1.6 laptops: effectively throwing away 0.6 laptop.
Also I see no reason why a non-upgradeable laptop would also be non-repairable.