algolia / vue-instantsearch

👀 Algolia components for building search UIs with Vue.js
https://www.algolia.com/doc/guides/building-search-ui/what-is-instantsearch/vue
MIT License
854 stars 157 forks source link

Trailing Slash #1124

Closed freeboxd closed 2 years ago

freeboxd commented 2 years ago

Feature ⚡️

What is your use case for such a feature?

I am using the Pagination component (AisPagination).

What is your proposal

I would like to add a way to add trailing slashes to hrefs such as the pagination ones

What is the version you are using?

Ver ^4.3.3

Haroenv commented 2 years ago

The default history router gives complete URLs, so they have a trailing slash if that's the page you loaded, as you can see here https://codesandbox.io/s/sweet-kapitsa-9sfolu?file=/src/App.vue

Do you mind elaborating what's different in your case?

the history router has an option createURL you can use to customise the urls that get written

freeboxd commented 2 years ago

createURL option solved my problem. Thank you, I wasn't aware