Shortly after it came out it was noticed that the M4 MacMini's SSD was on a small pcb which raised the possibility of of upgrading it yourself.
The first upgrades involved desoldering the SSD chip and replacing it with a higher capacity one. Now complete replacement pcbs are available from a few different sources.
I found this video interesting in that they explain their reverse engineering decisions which resulted in a cheaper and more performant design:
We Finally Beat Apple's M4 SSD - Bigger, Faster, Cheaper - iBoff RCC
https://youtu.be/F3CYj37bxDETechnical design discussion starts at 6:30.