Instead of this, create factory constructors for both hash navigator and history navigator. It will be more readable.