/opt/canhelp/node_modules/next/dist/esm/client/components
NameSizeModeActions
builtin/-0755rm
errors/-0755rm
http-access-fallback/-0755rm
metadata/-0755rm
router-reducer/-0755rm
segment-cache-impl/-0755rm
styles/-0755rm
app-router-announcer.js27570644editdlrm
app-router-announcer.js.map46600644editdlrm
app-router-headers.js16750644editdlrm
app-router-headers.js.map30140644editdlrm
app-router-instance.js130370644editdlrm
app-router-instance.js.map211310644editdlrm
app-router.js230670644editdlrm
app-router.js.map350120644editdlrm
bailout-to-client-rendering.js12360644editdlrm
bailout-to-client-rendering.js.map17060644editdlrm
bfcache.js45680644editdlrm
bfcache.js.map63940644editdlrm
client-page.js25190644editdlrm
client-page.js.map39190644editdlrm
client-segment.js21060644editdlrm
client-segment.js.map30990644editdlrm
dev-root-http-access-fallback-boundary.js9010644editdlrm
dev-root-http-access-fallback-boundary.js.map12920644editdlrm
error-boundary.js47300644editdlrm
error-boundary.js.map74540644editdlrm
forbidden.js15430644editdlrm
forbidden.js.map19880644editdlrm
handle-isr-error.js7090644editdlrm
handle-isr-error.js.map13160644editdlrm
hooks-server-context.js5340644editdlrm
hooks-server-context.js.map11330644editdlrm
is-next-router-error.js4810644editdlrm
is-next-router-error.js.map9220644editdlrm
layout-router.js264060644editdlrm
layout-router.js.map378500644editdlrm
links.js125330644editdlrm
links.js.map210600644editdlrm
match-segments.js5240644editdlrm
match-segments.js.map10340644editdlrm
nav-failure-handler.js16140644editdlrm
nav-failure-handler.js.map28270644editdlrm
navigation-untracked.js23970644editdlrm
navigation-untracked.js.map33740644editdlrm
navigation.js91180644editdlrm
navigation.js.map128070644editdlrm
navigation.react-server.js19440644editdlrm
navigation.react-server.js.map27680644editdlrm
noop-head.js940644editdlrm
noop-head.js.map2330644editdlrm
not-found.js13560644editdlrm
not-found.js.map17520644editdlrm
promise-queue.js37120644editdlrm
promise-queue.js.map35910644editdlrm
redirect-boundary.js22220644editdlrm
redirect-boundary.js.map39400644editdlrm
redirect-error.js11230644editdlrm
redirect-error.js.map21030644editdlrm
redirect-status-code.js4250644editdlrm
redirect-status-code.js.map3190644editdlrm
redirect.js38220644editdlrm
redirect.js.map58370644editdlrm
render-from-template-context.js4560644editdlrm
render-from-template-context.js.map6670644editdlrm
segment-cache.js60040644editdlrm
segment-cache.js.map88230644editdlrm
static-generation-bailout.js4660644editdlrm
static-generation-bailout.js.map8770644editdlrm
unauthorized.js15700644editdlrm
unauthorized.js.map20200644editdlrm
unrecognized-action-error.js9230644editdlrm
unrecognized-action-error.js.map14780644editdlrm
unresolved-thenable.js2270644editdlrm
unresolved-thenable.js.map4410644editdlrm
unstable-rethrow.browser.js4330644editdlrm
unstable-rethrow.browser.js.map8410644editdlrm
unstable-rethrow.js7120644editdlrm
unstable-rethrow.js.map11120644editdlrm
unstable-rethrow.server.js8540644editdlrm
unstable-rethrow.server.js.map15660644editdlrm
use-action-queue.js19210644editdlrm
use-action-queue.js.map32730644editdlrm
Edit: /opt/canhelp/node_modules/next/dist/esm/client/components/navigation-untracked.js (2397B)
import { useContext } from 'react'; import { PathnameContext } from '../../shared/lib/hooks-client-context.shared-runtime'; /** * This checks to see if the current render has any unknown route parameters. * It's used to trigger a different render path in the error boundary. * * @returns true if there are any unknown route parameters, false otherwise */ function hasFallbackRouteParams() { if (typeof window === 'undefined') { // AsyncLocalStorage should not be included in the client bundle. const { workUnitAsyncStorage } = require('../../server/app-render/work-unit-async-storage.external'); const workUnitStore = workUnitAsyncStorage.getStore(); if (!workUnitStore) return false; switch(workUnitStore.type){ case 'prerender': case 'prerender-client': case 'prerender-ppr': const fallbackParams = workUnitStore.fallbackRouteParams; return fallbackParams ? fallbackParams.size > 0 : false; case 'prerender-legacy': case 'request': case 'prerender-runtime': case 'cache': case 'private-cache': case 'unstable-cache': break; default: workUnitStore; } return false; } return false; } /** * This returns a `null` value if there are any unknown route parameters, and * otherwise returns the pathname from the context. This is an alternative to * `usePathname` that is used in the error boundary to avoid rendering the * error boundary when there are unknown route parameters. This doesn't throw * when accessed with unknown route parameters. * * @returns * * @internal */ export function useUntrackedPathname() { // If there are any unknown route parameters we would typically throw // an error, but this internal method allows us to return a null value instead // for components that do not propagate the pathname to the static shell (like // the error boundary). if (hasFallbackRouteParams()) { return null; } // This shouldn't cause any issues related to conditional rendering because // the environment will be consistent for the render. // eslint-disable-next-line react-hooks/rules-of-hooks return useContext(PathnameContext); } //# sourceMappingURL=navigation-untracked.js.map