repo
stringlengths
7
64
file_url
stringlengths
81
338
file_path
stringlengths
5
257
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:25:31
2026-01-05 01:50:38
truncated
bool
2 classes
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/tutorials/address-book/app/root.tsx
tutorials/address-book/app/root.tsx
import { Form, Scripts, ScrollRestoration, isRouteErrorResponse, } from "react-router"; import type { Route } from "./+types/root"; import appStylesHref from "./app.css?url"; export default function App() { return ( <> <div id="sidebar"> <h1>React Router Contacts</h1> <div> ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/tutorials/address-book/app/data.ts
tutorials/address-book/app/data.ts
//////////////////////////////////////////////////////////////////////////////// // 🛑 Nothing in here has anything to do with React Router, it's just a fake database //////////////////////////////////////////////////////////////////////////////// import { matchSorter } from "match-sorter"; // @ts-expect-error - no ty...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-query-parsing/vite.config.ts
examples/custom-query-parsing/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-query-parsing/src/App.tsx
examples/custom-query-parsing/src/App.tsx
import * as React from "react"; import * as JSURL from "jsurl"; import type { NavigateOptions } from "react-router-dom"; import { Routes, Route, Link, useSearchParams } from "react-router-dom"; export default function App() { return ( <div> <h1>Custom Query Parsing Example</h1> <p> This exam...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-query-parsing/src/main.tsx
examples/custom-query-parsing/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </Re...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-query-parsing/src/vite-env.d.ts
examples/custom-query-parsing/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-query-parsing/types/jsurl.d.ts
examples/custom-query-parsing/types/jsurl.d.ts
declare module "jsurl" { type Nullable<T> = T | null | undefined; export function stringify(input: any): string; export function parse(input?: Nullable<string>): Nullable<any>; }
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth/vite.config.ts
examples/auth/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth/src/App.tsx
examples/auth/src/App.tsx
import * as React from "react"; import { Routes, Route, Link, useNavigate, useLocation, Navigate, Outlet, } from "react-router-dom"; import { fakeAuthProvider } from "./auth"; export default function App() { return ( <AuthProvider> <h1>Auth Example</h1> <p> This example demonst...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth/src/main.tsx
examples/auth/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")!).render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </R...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth/src/auth.ts
examples/auth/src/auth.ts
/** * This represents some generic auth provider API, like Firebase. */ const fakeAuthProvider = { isAuthenticated: false, signin(callback: VoidFunction) { fakeAuthProvider.isAuthenticated = true; setTimeout(callback, 100); // fake async }, signout(callback: VoidFunction) { fakeAuthProvider.isAuth...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth/src/vite-env.d.ts
examples/auth/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/view-transitions/vite.config.ts
examples/view-transitions/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/view-transitions/src/main.tsx
examples/view-transitions/src/main.tsx
import * as React from "react"; import * as ReactDOMClient from "react-dom/client"; import { Await, createBrowserRouter, defer, Form, json, Link, NavLink, Outlet, RouterProvider, unstable_useViewTransitionState, useActionData, useLoaderData, useLocation, useNavigate, useNavigation, usePa...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/view-transitions/src/vite-env.d.ts
examples/view-transitions/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/data-router/vite.config.ts
examples/data-router/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/data-router/src/todos.ts
examples/data-router/src/todos.ts
export interface Todos { [key: string]: string; } const TODOS_KEY = "todos"; export const uuid = () => Math.random().toString(36).substr(2, 9); export function saveTodos(todos: Todos): void { return localStorage.setItem(TODOS_KEY, JSON.stringify(todos)); } function initializeTodos(): Todos { let todos: Todos ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/data-router/src/main.tsx
examples/data-router/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import App from "./app"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <App /> </React.StrictMode>, );
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/data-router/src/app.tsx
examples/data-router/src/app.tsx
import * as React from "react"; import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router-dom"; import { Await, createBrowserRouter, defer, Form, Link, Outlet, RouterProvider, useAsyncError, useAsyncValue, useFetcher, useFetchers, useLoaderData, useNavigation, useParams, us...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/data-router/src/vite-env.d.ts
examples/data-router/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/navigation-blocking/vite.config.ts
examples/navigation-blocking/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/navigation-blocking/src/main.tsx
examples/navigation-blocking/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import App from "./app"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <App /> </React.StrictMode>, );
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/navigation-blocking/src/app.tsx
examples/navigation-blocking/src/app.tsx
import * as React from "react"; import type { unstable_Blocker as Blocker, unstable_BlockerFunction as BlockerFunction, } from "react-router-dom"; import { useActionData } from "react-router-dom"; import { createBrowserRouter, createRoutesFromElements, Form, json, Link, Outlet, Route, RouterProvider...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/navigation-blocking/src/vite-env.d.ts
examples/navigation-blocking/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/search-params/vite.config.ts
examples/search-params/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/search-params/src/App.tsx
examples/search-params/src/App.tsx
import * as React from "react"; import { Link, Route, Routes, useSearchParams } from "react-router-dom"; export default function App() { return ( <div> <h1>Search Params Example</h1> <p> This example demonstrates a simple search page that makes a request for user data to the GitHub A...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/search-params/src/main.tsx
examples/search-params/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import App from "./App"; import "./index.css"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </Re...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/search-params/src/vite-env.d.ts
examples/search-params/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth-router-provider/vite.config.ts
examples/auth-router-provider/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth-router-provider/src/App.tsx
examples/auth-router-provider/src/App.tsx
import type { LoaderFunctionArgs } from "react-router-dom"; import { Form, Link, Outlet, RouterProvider, createBrowserRouter, redirect, useActionData, useFetcher, useLocation, useNavigation, useRouteLoaderData, } from "react-router-dom"; import { fakeAuthProvider } from "./auth"; const router = c...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth-router-provider/src/main.tsx
examples/auth-router-provider/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")!).render( <React.StrictMode> <App /> </React.StrictMode>, );
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth-router-provider/src/auth.ts
examples/auth-router-provider/src/auth.ts
interface AuthProvider { isAuthenticated: boolean; username: null | string; signin(username: string): Promise<void>; signout(): Promise<void>; } /** * This represents some generic auth provider API, like Firebase. */ export const fakeAuthProvider: AuthProvider = { isAuthenticated: false, username: null, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/auth-router-provider/src/vite-env.d.ts
examples/auth-router-provider/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/basic/vite.config.ts
examples/basic/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/basic/src/App.tsx
examples/basic/src/App.tsx
import { Routes, Route, Outlet, Link } from "react-router-dom"; export default function App() { return ( <div> <h1>Basic Example</h1> <p> This example demonstrates some of the core features of React Router including nested <code>&lt;Route&gt;</code>s,{" "} <code>&lt;Outlet&gt...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/basic/src/main.tsx
examples/basic/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")!).render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </R...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/basic/src/vite-env.d.ts
examples/basic/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr-data-router/src/App.tsx
examples/ssr-data-router/src/App.tsx
import type { RouteObject } from "react-router-dom"; import { Outlet, Link, useLoaderData, redirect } from "react-router-dom"; export const routes: RouteObject[] = [ { path: "/", element: <Layout />, children: [ { index: true, loader: homeLoader, element: <Home />, }, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr-data-router/src/lazy.tsx
examples/ssr-data-router/src/lazy.tsx
import { useLoaderData } from "react-router-dom"; interface LazyLoaderData { date: string; } export const loader = async (): Promise<LazyLoaderData> => { await new Promise((r) => setTimeout(r, 500)); return { date: new Date().toISOString(), }; }; function LazyPage() { let data = useLoaderData() as Lazy...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr-data-router/src/entry.server.tsx
examples/ssr-data-router/src/entry.server.tsx
import type * as express from "express"; import * as React from "react"; import ReactDOMServer from "react-dom/server"; import { createStaticHandler, createStaticRouter, StaticRouterProvider, } from "react-router-dom/server"; import { routes } from "./App"; export async function render( request: express.Reques...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr-data-router/src/vite-env.d.ts
examples/ssr-data-router/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr-data-router/src/entry.client.tsx
examples/ssr-data-router/src/entry.client.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { createBrowserRouter, matchRoutes, RouterProvider, } from "react-router-dom"; import { routes } from "./App"; hydrate(); async function hydrate() { // Determine if any of the initial routes are lazy let lazyMatches = matc...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr/src/App.tsx
examples/ssr/src/App.tsx
import { Routes, Route, Outlet, Link } from "react-router-dom"; export default function App() { return ( <div> <h1>Server Rendering Example</h1> <p> If you check out the HTML source of this page, you'll notice that it already contains the HTML markup of the app that was sent from the...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr/src/entry.server.tsx
examples/ssr/src/entry.server.tsx
import * as React from "react"; import ReactDOMServer from "react-dom/server"; import { StaticRouter } from "react-router-dom/server"; import App from "./App"; export function render(url: string) { return ReactDOMServer.renderToString( <React.StrictMode> <StaticRouter location={url}> <App /> ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr/src/vite-env.d.ts
examples/ssr/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/ssr/src/entry.client.tsx
examples/ssr/src/entry.client.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import "./index.css"; import App from "./App"; ReactDOM.hydrateRoot( document.getElementById("app"), <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </React.S...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/error-boundaries/vite.config.ts
examples/error-boundaries/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/error-boundaries/src/main.tsx
examples/error-boundaries/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import App from "./app"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <App /> </React.StrictMode>, );
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/error-boundaries/src/routes.tsx
examples/error-boundaries/src/routes.tsx
import type { LoaderFunctionArgs } from "react-router-dom"; import { isRouteErrorResponse, json, Link, Outlet, useLoaderData, useRouteError, } from "react-router-dom"; export function Fallback() { return <p>Performing initial data "load"</p>; } export function Layout() { return ( <> <nav> ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/error-boundaries/src/app.tsx
examples/error-boundaries/src/app.tsx
import { createBrowserRouter, Outlet, RouterProvider } from "react-router-dom"; import "./index.css"; import { Fallback, Layout, RootErrorBoundary, Project, ProjectErrorBoundary, projectLoader, } from "./routes"; let router = createBrowserRouter([ { path: "/", element: <Layout />, children: ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/error-boundaries/src/vite-env.d.ts
examples/error-boundaries/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading/vite.config.ts
examples/lazy-loading/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading/src/App.tsx
examples/lazy-loading/src/App.tsx
import * as React from "react"; import { Routes, Route, Outlet, Link } from "react-router-dom"; const About = React.lazy(() => import("./pages/About")); const Dashboard = React.lazy(() => import("./pages/Dashboard")); export default function App() { return ( <div> <h1>Lazy Loading Example</h1> <p> ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading/src/main.tsx
examples/lazy-loading/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </Re...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading/src/vite-env.d.ts
examples/lazy-loading/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading/src/pages/About.tsx
examples/lazy-loading/src/pages/About.tsx
function AboutPage() { return ( <div> <h2>About</h2> </div> ); } export default AboutPage;
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading/src/pages/Dashboard.tsx
examples/lazy-loading/src/pages/Dashboard.tsx
import { Routes, Route, Outlet, Link } from "react-router-dom"; export default function Dashboard() { // These routes are defined when this component is loaded on demand via // dynamic import() on the home page! return ( <Routes> <Route path="/" element={<DashboardLayout />}> <Route index eleme...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/basic-data-router/vite.config.ts
examples/basic-data-router/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/basic-data-router/src/main.tsx
examples/basic-data-router/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import App from "./app"; ReactDOM.createRoot(document.getElementById("root")!).render( <React.StrictMode> <App /> </React.StrictMode>, );
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/basic-data-router/src/app.tsx
examples/basic-data-router/src/app.tsx
import { createBrowserRouter, RouterProvider, useLoaderData, } from "react-router-dom"; import "./index.css"; let router = createBrowserRouter([ { path: "/", loader: () => ({ message: "Hello Data Router!" }), Component() { let data = useLoaderData() as { message: string }; return <h1>{...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/basic-data-router/src/vite-env.d.ts
examples/basic-data-router/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-filter-link/vite.config.ts
examples/custom-filter-link/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-filter-link/src/App.tsx
examples/custom-filter-link/src/App.tsx
import * as React from "react"; import { Routes, Route, Outlet, Link, useSearchParams, useParams, } from "react-router-dom"; import type { LinkProps } from "react-router-dom"; import { VisuallyHidden } from "@reach/visually-hidden"; import { brands, filterByBrand, getSneakerById, SNEAKERS } from "./snkrs";...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-filter-link/src/main.tsx
examples/custom-filter-link/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </Re...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-filter-link/src/snkrs.ts
examples/custom-filter-link/src/snkrs.ts
interface Sneaker { id: string; colorway: string; imageUrl: string; model: string; brand: string; } let SNEAKERS: Sneaker[] = [ { id: "1", colorway: "Pine Green", imageUrl: "https://images.mcan.sh/b_auto,c_pad,f_auto,h_400,q_auto,w_400/v1/shoes/bkkj0lqzlwlwdwtofqxs", model: "Blazer Lo...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-filter-link/src/vite-env.d.ts
examples/custom-filter-link/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/scroll-restoration/vite.config.ts
examples/scroll-restoration/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/scroll-restoration/src/main.tsx
examples/scroll-restoration/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import App from "./app"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <App /> </React.StrictMode>, );
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/scroll-restoration/src/app.tsx
examples/scroll-restoration/src/app.tsx
import * as React from "react"; import type { Location, useMatches } from "react-router-dom"; import { createBrowserRouter, Link, Outlet, RouterProvider, ScrollRestoration, useLoaderData, useLocation, useNavigation, } from "react-router-dom"; import "./index.css"; let router = createBrowserRouter([ ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/scroll-restoration/src/vite-env.d.ts
examples/scroll-restoration/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-link/vite.config.ts
examples/custom-link/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-link/src/App.tsx
examples/custom-link/src/App.tsx
import { Routes, Route, Outlet, Link, useMatch, useResolvedPath, } from "react-router-dom"; import type { LinkProps } from "react-router-dom"; export default function App() { return ( <div> <h1>Custom Link Example</h1> <p> This example demonstrates how to create a custom{" "} ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-link/src/main.tsx
examples/custom-link/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </Re...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/custom-link/src/vite-env.d.ts
examples/custom-link/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/route-objects/vite.config.ts
examples/route-objects/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/route-objects/src/App.tsx
examples/route-objects/src/App.tsx
import type { RouteObject } from "react-router-dom"; import { Outlet, Link, useRoutes, useParams } from "react-router-dom"; export default function App() { let routes: RouteObject[] = [ { path: "/", element: <Layout />, children: [ { index: true, element: <Home /> }, { ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/route-objects/src/main.tsx
examples/route-objects/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import { BrowserRouter } from "react-router-dom"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </Re...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/route-objects/src/vite-env.d.ts
examples/route-objects/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal/vite.config.ts
examples/modal/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal/src/App.tsx
examples/modal/src/App.tsx
import * as React from "react"; import { Routes, Route, Outlet, Link, useLocation, useNavigate, useParams, } from "react-router-dom"; import { Dialog } from "@reach/dialog"; import "@reach/dialog/styles.css"; import { IMAGES, getImageById } from "./images"; export default function App() { let location...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal/src/images.ts
examples/modal/src/images.ts
let IMAGES = [ { id: 0, title: "Enjoying a cup of coffee", src: "https://images.unsplash.com/photo-1631016800696-5ea8801b3c2a?crop=entropy&cs=tinysrgb&fit=crop&fm=jpg&h=400&ixid=MnwxfDB8MXxyYW5kb218MHx8fHx8fHx8MTYzMzM2Mzg4Ng&ixlib=rb-1.2.1&q=80&w=400", }, { id: 1, title: "Magical winter sunris...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal/src/main.tsx
examples/modal/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom"; import { BrowserRouter } from "react-router-dom"; import App from "./App"; import "./index.css"; ReactDOM.render( <React.StrictMode> <BrowserRouter> <App /> </BrowserRouter> </React.StrictMode>, document.getElementById("root"),...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal/src/vite-env.d.ts
examples/modal/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading-router-provider/vite.config.ts
examples/lazy-loading-router-provider/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading-router-provider/src/App.tsx
examples/lazy-loading-router-provider/src/App.tsx
import { Outlet, Link, createBrowserRouter, RouterProvider, useNavigation, } from "react-router-dom"; const router = createBrowserRouter([ { path: "/", element: <Layout />, children: [ { index: true, element: <Home />, }, { path: "about", // Sin...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading-router-provider/src/main.tsx
examples/lazy-loading-router-provider/src/main.tsx
import * as React from "react"; import * as ReactDOM from "react-dom/client"; import "./index.css"; import App from "./App"; ReactDOM.createRoot(document.getElementById("root")).render( <React.StrictMode> <App /> </React.StrictMode>, );
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading-router-provider/src/vite-env.d.ts
examples/lazy-loading-router-provider/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading-router-provider/src/pages/About.tsx
examples/lazy-loading-router-provider/src/pages/About.tsx
import { useLoaderData } from "react-router-dom"; export async function loader() { await new Promise((r) => setTimeout(r, 500)); return "I came from the About.tsx loader function!"; } export function Component() { let data = useLoaderData() as string; return ( <div> <h2>About</h2> <p>{data}</...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/lazy-loading-router-provider/src/pages/Dashboard.tsx
examples/lazy-loading-router-provider/src/pages/Dashboard.tsx
import { Outlet, Link, useLoaderData } from "react-router-dom"; export function DashboardLayout() { return ( <div> <nav> <ul> <li> <Link to="/dashboard">Dashboard Home</Link> </li> <li> <Link to="/dashboard/messages">Messages</Link> </...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal-route-with-outlet/vite.config.ts
examples/modal-route-with-outlet/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal-route-with-outlet/src/App.tsx
examples/modal-route-with-outlet/src/App.tsx
import * as React from "react"; import { Outlet, Link, useNavigate, useParams, RouterProvider, createBrowserRouter, } from "react-router-dom"; import { Dialog } from "@reach/dialog"; import "@reach/dialog/styles.css"; import { IMAGES, getImageById } from "./images"; const router = createBrowserRouter([ ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal-route-with-outlet/src/images.ts
examples/modal-route-with-outlet/src/images.ts
let IMAGES = [ { id: 0, title: "Enjoying a cup of coffee", src: "https://images.unsplash.com/photo-1631016800696-5ea8801b3c2a?crop=entropy&cs=tinysrgb&fit=crop&fm=jpg&h=400&ixid=MnwxfDB8MXxyYW5kb218MHx8fHx8fHx8MTYzMzM2Mzg4Ng&ixlib=rb-1.2.1&q=80&w=400", }, { id: 1, title: "Magical winter sunris...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal-route-with-outlet/src/main.tsx
examples/modal-route-with-outlet/src/main.tsx
import * as React from "react"; import ReactDOM from "react-dom/client"; import App from "./App"; import "./index.css"; const root = document.getElementById("root"); if (!root) throw new Error("Root element not found"); ReactDOM.createRoot(root).render( <React.StrictMode> <App /> </React.StrictMode>, );
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/modal-route-with-outlet/src/vite-env.d.ts
examples/modal-route-with-outlet/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/notes/vite.config.ts
examples/notes/vite.config.ts
import * as path from "path"; import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import rollupReplace from "@rollup/plugin-replace"; // https://vitejs.dev/config/ export default defineConfig({ server: { port: 3000, }, plugins: [ rollupReplace({ preventAssignment: true, ...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/examples/notes/src/vite-env.d.ts
examples/notes/src/vite-env.d.ts
/// <reference types="vite/client" />
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/packages/react-router-architect/server.ts
packages/react-router-architect/server.ts
import type { AppLoadContext, UNSAFE_MiddlewareEnabled as MiddlewareEnabled, ServerBuild, RouterContextProvider, } from "react-router"; import { createRequestHandler as createReactRouterRequestHandler } from "react-router"; import { readableStreamToString } from "@react-router/node"; import type { APIGatewayP...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/packages/react-router-architect/binaryTypes.ts
packages/react-router-architect/binaryTypes.ts
/** * Common binary MIME types * @see https://github.com/architect/functions/blob/45254fc1936a1794c185aac07e9889b241a2e5c6/src/http/helpers/binary-types.js */ const binaryTypes = [ "application/octet-stream", // Docs "application/epub+zip", "application/msword", "application/pdf", "application/rtf", "a...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/packages/react-router-architect/tsup.config.ts
packages/react-router-architect/tsup.config.ts
import { defineConfig } from "tsup"; // @ts-ignore - out of scope import { createBanner } from "../../build.utils.js"; import pkg from "./package.json"; const entry = ["index.ts"]; export default defineConfig([ { clean: true, entry, format: ["cjs", "esm"], outDir: "dist", dts: true, banner...
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false
remix-run/react-router
https://github.com/remix-run/react-router/blob/aaa150616e619efc8d26c092e8625962c2fb4246/packages/react-router-architect/index.ts
packages/react-router-architect/index.ts
export { createArcTableSessionStorage } from "./sessions/arcTableSessionStorage"; export type { GetLoadContextFunction, RequestHandler } from "./server"; export { createRequestHandler } from "./server";
typescript
MIT
aaa150616e619efc8d26c092e8625962c2fb4246
2026-01-04T15:29:26.871957Z
false