UNPKG

vike

Version:

The Framework *You* Control - Next.js & Nuxt alternative for unprecedented flexibility and dependability.

18 lines (17 loc) 646 B
import '../assertEnvServer.js'; export { navigate }; export { reload }; export { prefetch }; export { onPopState }; import { assertWarning } from '../../utils/assert.js'; // `never` to ensure package.json#exports["./client/router"].types points to type defined by the client-side code const navigate = (() => warnNoEffect('navigate')); const reload = (() => warnNoEffect('reload')); const prefetch = (() => warnNoEffect('prefetch')); const onPopState = (() => { }); function warnNoEffect(caller) { assertWarning(false, `Calling ${caller}() on the server-side has no effect`, { showStackTrace: true, onlyOnce: false, }); }