update remix imports + format
This commit is contained in:
@@ -4,3 +4,4 @@ coverage
|
||||
pnpm-lock.yaml
|
||||
build
|
||||
.cache
|
||||
packages/website/public/api
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { hydrate } from "react-dom";
|
||||
import { RemixBrowser } from "remix";
|
||||
import { hydrate } from "react-dom"
|
||||
import { RemixBrowser } from "@remix-run/react"
|
||||
|
||||
hydrate(<RemixBrowser />, document);
|
||||
hydrate(<RemixBrowser />, document)
|
||||
|
||||
@@ -1,21 +1,21 @@
|
||||
import { renderToString } from "react-dom/server";
|
||||
import { RemixServer } from "remix";
|
||||
import type { EntryContext } from "remix";
|
||||
import { renderToString } from "react-dom/server"
|
||||
import type { EntryContext } from "@remix-run/node"
|
||||
import { RemixServer } from "@remix-run/react"
|
||||
|
||||
export default function handleRequest(
|
||||
request: Request,
|
||||
responseStatusCode: number,
|
||||
responseHeaders: Headers,
|
||||
remixContext: EntryContext
|
||||
remixContext: EntryContext,
|
||||
) {
|
||||
const markup = renderToString(
|
||||
<RemixServer context={remixContext} url={request.url} />
|
||||
);
|
||||
<RemixServer context={remixContext} url={request.url} />,
|
||||
)
|
||||
|
||||
responseHeaders.set("Content-Type", "text/html");
|
||||
responseHeaders.set("Content-Type", "text/html")
|
||||
|
||||
return new Response("<!DOCTYPE html>" + markup, {
|
||||
status: responseStatusCode,
|
||||
headers: responseHeaders
|
||||
});
|
||||
headers: responseHeaders,
|
||||
})
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import type { ComponentPropsWithoutRef } from "react"
|
||||
import { Link } from "remix"
|
||||
import { Link } from "@remix-run/react"
|
||||
import { ExternalLink } from "~/modules/dom/external-link"
|
||||
|
||||
export type AppLinkProps = ComponentPropsWithoutRef<"a"> & {
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
import packageJson from "reacord/package.json"
|
||||
import type { LinksFunction, LoaderFunction, MetaFunction } from "remix"
|
||||
import type {
|
||||
LinksFunction,
|
||||
LoaderFunction,
|
||||
MetaFunction,
|
||||
} from "@remix-run/node"
|
||||
import {
|
||||
Links,
|
||||
LiveReload,
|
||||
@@ -8,7 +12,7 @@ import {
|
||||
Scripts,
|
||||
ScrollRestoration,
|
||||
useLoaderData,
|
||||
} from "remix"
|
||||
} from "@remix-run/react"
|
||||
import bannerUrl from "~/assets/banner.png"
|
||||
import faviconUrl from "~/assets/favicon.png"
|
||||
import { GuideLinksProvider } from "~/modules/navigation/guide-links-context"
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import clsx from "clsx"
|
||||
import { Outlet } from "remix"
|
||||
import { Outlet } from "@remix-run/react"
|
||||
import { ActiveLink } from "~/modules/navigation/active-link"
|
||||
import { AppLink } from "~/modules/navigation/app-link"
|
||||
import { useGuideLinksContext } from "~/modules/navigation/guide-links-context"
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
// ***********************************************************
|
||||
|
||||
// Import commands.js using ES2015 syntax:
|
||||
import './commands'
|
||||
import "./commands"
|
||||
|
||||
// Alternatively you can use CommonJS syntax:
|
||||
// require('./commands')
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
"@headlessui/react": "^1.5.0",
|
||||
"@heroicons/react": "^1.0.6",
|
||||
"@reach/rect": "^0.17.0",
|
||||
"@remix-run/node": "^1.4.1",
|
||||
"@remix-run/react": "^1.4.1",
|
||||
"@remix-run/serve": "^1.4.1",
|
||||
"@tailwindcss/typography": "^0.5.2",
|
||||
@@ -25,8 +26,7 @@
|
||||
"react-dom": "^18.0.0",
|
||||
"react-focus-on": "^3.5.4",
|
||||
"react-router": "^6.3.0",
|
||||
"react-router-dom": "^6.3.0",
|
||||
"remix": "^1.4.1"
|
||||
"react-router-dom": "^6.3.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@remix-run/dev": "^1.4.1",
|
||||
|
||||
Reference in New Issue
Block a user