how to coding "if trigger hit nothing"?

I want to created java script that create a plate (when clicking at something).If plate hit something, then do nothing.If plate hit nothing,then destroy it.Thank for help.

Destroy it after a set period of time

Destroy (gameObject, 3);

If you need something a bit more sophisticated you can start a coroutine for the destroy and stop the coroutine in OnCollision.