debut des details de la page. Vu que c'est le troisieme (euh quatrieme?) composant, c'etait un peu plus rapide, mais heureusement que claude est la pour repasser derriere mes erreurs prcq en solo je n'y arriverais pas du tout!

This commit is contained in:
camille
2026-03-27 17:49:26 +01:00
parent 24e85c4471
commit 43589e583e
92 changed files with 12959 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
import { ErreStream } from 'erre'
import { TokensToRegexpOptions, ParseOptions, pathToRegexp } from 'path-to-regexp'
type Callback = (...args: any[]) => any
export type URLWithParams = URL & { params: Record<string, string> }
export type RawthOptions = TokensToRegexpOptions & ParseOptions & {
base: string
silentErrors: boolean
}
// internal methods that probably you will never use by yourselves
export declare const toRegexp: typeof pathToRegexp
export declare const toPath: (path: string, params: Record<string, string>, options: RawthOptions) => string
export declare const toURL: (path: string, pathRegExp: RegExp, options: RawthOptions) => URLWithParams
export declare const match: (path: string, pathRegExp: RegExp) => boolean
export declare const createURLStreamPipe: (pathRegExp: RegExp, options: RawthOptions) => Callback[]
// public API
export declare const router: ErreStream<string, string, string>
export declare const defaults: RawthOptions
export declare const configure: (options: Partial<RawthOptions>) => RawthOptions
export declare function route(path: string): ErreStream<URLWithParams, URLWithParams, URLWithParams>
export default route