diff --git a/README.md b/README.md index d1aa340..46d77b6 100644 --- a/README.md +++ b/README.md @@ -124,21 +124,20 @@ router.get() //=> { // } ``` -To use search query like `?a=1&b=2` in routes you need to set `search` option: +To disable the automatic parsing of search params in routes you need to set `search` option. +Router will now treat search query like `?a=1&b=2` as a string. Parameters order will be critical. ```js -createRouter( - { - home: '/p/?page=home' - }, - { - search: true - } -) -``` +createRouter({ home: '/posts?page=general' }, { search: true }) -Router will work with `?search` part as a string. Parameters order will -be critical. +location.href = '/posts/?page=general' +router.get() //=> { +// path: '/posts?page=general', +// route: 'list', +// params: { }, +// search: { } +// } +``` ### Clicks Tracking