UNPKG

@wener/console

Version:

Base console UI toolkit

19 lines (18 loc) 541 B
import React, { forwardRef } from "react"; import { Link as _Link, useInRouterContext } from "react-router-dom"; export const Link = /*#__PURE__*/ forwardRef((props, ref)=>{ if (useInRouterContext()) { return /*#__PURE__*/ React.createElement(_Link, { to: props.href, ...props }); } // if (useIsNextJS()) { // return <NextLink {...props} />; // } return /*#__PURE__*/ React.createElement("a", { ...props, ref: ref }); }); //# sourceMappingURL=Link.js.map