Every formula evaluates to something -- a string, a number, an error, ...
So you can't really delete the contents and still keep the formula.
But you could modify the formula so that it returns an empty string ("") and
that makes the cell look empty.
You could modify the formula to look at the other cells it needs and if those
are empty, then return that "" string.
For example, if I had a formula that just added 12 to the value in A1, I could
use:
=A1+12
But if I wanted to make the cell look empty until something is put into A1, I
could use one of these:
=if(a1="","",a1+12)
or
=if(isnumber(a1),a1+12,"")