Version 4 introduces push state. There are two major changes:
Config now includes hash
and basePath
.
routerConfig : Config Route
routerConfig =
{ hash = True
, basePath = ""
, matchers = matchers
, notFound = NotFoundRoute
}
Most functions in Hop now require your router config. For example instead of:
navigateTo path
addQuery query location
It is now:
navigateTo config path
addQuery config query location
This is because Hop needs to know if you are using hash or path routing.