/ x / ruck@v5.0.0 / useRoute.mjs

// @ts-check
import { useContext } from "react";
import RouteContext from "./RouteContext.mjs";
/** A React hook to use the current Ruck app route. */export default function useRoute() { const route = useContext(RouteContext); if (!route) throw TypeError("Context value missing."); return route;}
Ruck is an open source buildless React web application framework for Deno.
GitHub Stars
Go to latest

Version Info

Tagged at
a month ago

External Dependencies