UNPKG

vike

Version:

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

20 lines (19 loc) 823 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.onPopState = exports.prefetch = exports.reload = exports.navigate = void 0; const assert_js_1 = require("../../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')); exports.navigate = navigate; const reload = (() => warnNoEffect('reload')); exports.reload = reload; const prefetch = (() => warnNoEffect('prefetch')); exports.prefetch = prefetch; const onPopState = (() => { }); exports.onPopState = onPopState; function warnNoEffect(caller) { (0, assert_js_1.assertWarning)(false, `Calling ${caller}() on the server-side has no effect`, { showStackTrace: true, onlyOnce: false, }); }