Skip to content
This repository was archived by the owner on Jun 26, 2025. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 35 additions & 1 deletion index.d.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import type { SvelteComponentTyped } from "svelte";

interface TinroRoute {
url: string
from: string
Expand Down Expand Up @@ -81,7 +83,39 @@ declare interface TinroRouter {
export const active: any
export function meta(): TinroRouteMeta
export const router: TinroRouter
export class Route {

type RouteArgs = {
/**
* Exact o relative path of the route
* @default "/*"
*/
path?: string;

/**
* Is route fallback
* @default false
*/
fallback?: boolean;

/**
* Redirect route to the specified path
*/
redirect?: string;

/**
* Will be show only first matched with URL nested route
* @default false
*/
firstmatch?: boolean;

/**
* Name of the route to use in breadcrumbs
* @default null
*/
breadcrumb?: string;
}

export class Route extends SvelteComponentTyped<RouteArgs> {
$$prop_def: {
/**
* Exact o relative path of the route
Expand Down