This kind of thing happens all the time though. The most salient instances being when states enact abortion restrictions that are known to be unconstitutional and were historically subject to injunctions and ruled against.
There isn't a mechanism to stop unconstitutional laws from being passed or left on the books.
There isn't a mechanism to stop unconstitutional laws from being passed or left on the books.