Automatically detect compatibility mode if history.pushState is unusable or location.hash is set.
Added zoom state to the demo.