Minor Changes
-
BREAKING CHANGE: Removed the
ContextWithAuthandContextWithRequiredAuthhelper types. Derive auth-aware request context from the actual auth middleware tuple withMiddlewareContext, or use the coreContextWithEntryhelper when manually composing context types without a middleware tuple.import { requireAuth } from 'remix/auth-middleware' import type { MiddlewareContext } from 'remix/fetch-router' let protectedMiddleware = [requireAuth<AuthIdentity>()] as const type AppAuthContext = MiddlewareContext<typeof protectedMiddleware, AppContext>
-
auth()now installs resolved auth state ascontext.authin addition tocontext.get(Auth).requireAuth()narrowscontext.authandcontext.get(Auth)toGoodAuth<identity>for protected handlers.
Patch Changes
- Bumped
@remix-run/*dependencies: