import React, { useMemo } from "react"; import { render, screen } from "@testing-library/react"; import { createMemoryHistory } from "@nano-router/history"; import "@testing-library/jest-dom"; import { Routes, Route, Router, useLocation, Navigate } from "./index.js"; const routes = new Routes( new Route("posts", "/posts"), new Route("new", "/new"), ); const Location = () => { const location = useLocation(); return