I desperately needed a safer solution for styling SharePoint than using the great Modern Script Editor. After failing to find an open source solution, I made my own.
ChatGPT gives us the following sales pitch:
Are you looking for a way to add some style to your SharePoint site? Look no further than Pzl.Ext.Styler! This free SharePoint Framework solution allows you to easily customize the look and feel of your SharePoint site using CSS!
It’s super light weight and rather easy to implement. Add it to the site(s) that you want to style. Create a site called /sites/CDN, add a document library called Styling. Then copy the sample file and modify it.
Bear in mind that we’re playing cat and mouse with Microsoft here. If they change a class in SharePoint, your styling will probably break. Therefore I recommend using it for the necessary things, like hiding stupid stuff like Site name from the stock news web part. If you still want to go full banana, be my guest.
Here’s an example using mostly stock web parts with custom CSS styling: