@tanstack/react-router
Version:
Modern and scalable routing for React applications
34 lines (33 loc) • 1.02 kB
JavaScript
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
const React = require("react");
function _interopNamespaceDefault(e) {
const n = Object.create(null, { [Symbol.toStringTag]: { value: "Module" } });
if (e) {
for (const k in e) {
if (k !== "default") {
const d = Object.getOwnPropertyDescriptor(e, k);
Object.defineProperty(n, k, d.get ? d : {
enumerable: true,
get: () => e[k]
});
}
}
}
n.default = e;
return Object.freeze(n);
}
const React__namespace = /* @__PURE__ */ _interopNamespaceDefault(React);
const routerContext = React__namespace.createContext(null);
function getRouterContext() {
if (typeof document === "undefined") {
return routerContext;
}
if (window.__TSR_ROUTER_CONTEXT__) {
return window.__TSR_ROUTER_CONTEXT__;
}
window.__TSR_ROUTER_CONTEXT__ = routerContext;
return routerContext;
}
exports.getRouterContext = getRouterContext;
//# sourceMappingURL=routerContext.cjs.map
;