Hello I often encounter situations where it would be useful to be able to Serialize a custom class so that it appears in the inspector, BUT to also have it start off null. That is to say, you have to actively declare it a new MyClass() or click the + on the inspector to use it.
Yes, there is and it’s called SerializeReference.
Though be warned that while the Inspector will show the serialized class out-of-the-box, there is currently no built-in way to create a particular instance. Since SerializeReference does support polymorphism, you need some custom editor code to create an instance or to set it back to null.
You may create your own PropertyDrawer to handle the cases you need or you have to look for custom solutions by someone else that suits your needs.
There are other free plugins out there, though Odin Inspector is the best choice for the best ‘out of the box’ support for SerializeReference, while being paid.
I take this as Spiney’s answer has answered your question. So I took the liberty and marked his answer as the solution. I guess you should be able to change it if you want to, but I assume that’s fine?