@well-known-js/react-router
v1.0.2
Published
React Router resource route handlers for .well-known routes.
Downloads
434
Maintainers
Readme
@well-known-js/react-router
React Router resource-route loader for serving configured /.well-known/* routes.
Installation
pnpm add @well-known-js/react-router @well-known-js/core react-routerUsage
import { createWellKnownLoader } from "@well-known-js/react-router";
import config from "../../../well-known.config.js";
export const loader = createWellKnownLoader(config);Mount the loader from a resource route matching /.well-known/*. It returns standard Fetch API
responses with the content type declared by each provider and a 404 for unknown paths.
