Home > vue-router > createMemoryHistory
Creates a in-memory based history. The main purpose of this history is to handle SSR. It starts in a special location that is nowhere. It’s up to the user to replace that location with the starter location.
Signature:
export default function createMemoryHistory(base?: string): RouterHistory;
| Parameter | Type | Description |
|---|---|---|
| base | string |
Base applied to all urls, defaults to ‘/’ |
Returns:
RouterHistory
a history object that can be passed to the router constructor