Clearing hash react code