UNPKG

@carbon/ibm-products

Version:

Carbon for IBM Products

31 lines (27 loc) 867 B
/** * Copyright IBM Corp. 2020, 2025 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. */ import PropTypes from '../../_virtual/index.js'; import React__default from 'react'; const NavItemLink = /*#__PURE__*/React__default.forwardRef(function NavItemLink(props, ref) { const { element, ...rest } = props; return /*#__PURE__*/React__default.createElement(element, { ...rest, ref }); }); NavItemLink.displayName = 'NavItemLink'; NavItemLink.propTypes = { /** @type {elementType} The base element to use to build the link. Defaults to `a`, can also accept alternative tag names or custom components like `Link` from `react-router`. */ element: PropTypes.elementType }; NavItemLink.defaultProps = { element: 'a' }; export { NavItemLink as default };