un-proxy the api docs

This commit is contained in:
MapleLeaf
2022-01-12 21:14:05 -06:00
parent 7a09e8fdca
commit 2cdd324495
3 changed files with 2 additions and 9 deletions

View File

@@ -18,7 +18,7 @@ export const mainLinks: AppLinkProps[] = [
}, },
{ {
type: "internal", type: "internal",
to: "/api", to: "/api/",
children: ( children: (
<> <>
<CodeIcon className={inlineIconClass} /> API Reference <CodeIcon className={inlineIconClass} /> API Reference

View File

@@ -1,7 +0,0 @@
import type { LoaderFunction } from "remix"
// loading the api through a resource route lets us receive analytics and remix server logs for api pages
export const loader: LoaderFunction = ({ request, params }) => {
const url = new URL("/", request.url)
return fetch(`${url.toString()}/api-dist/${params["*"]}`)
}

View File

@@ -1,6 +1,6 @@
{ {
"entryPoints": ["../reacord/library/main.ts"], "entryPoints": ["../reacord/library/main.ts"],
"out": ["public/api-dist"], "out": ["public/api"],
"tsconfig": "../reacord/tsconfig.json", "tsconfig": "../reacord/tsconfig.json",
"excludeInternal": true, "excludeInternal": true,
"excludePrivate": true, "excludePrivate": true,