UNPKG

@opentiny/vue-renderless

Version:

An enterprise-class UI component library, support both Vue.js 2 and Vue.js 3, as well as PC and mobile.

22 lines (21 loc) 511 B
import "../chunk-G2ADBYYC.js"; const linkClick = ({ props, refs, router, emit, breadcrumbEmitter, constants }) => (event) => { const { replace, to, option } = props; const currentBreadcrumbItem = { link: refs.link, replace, to, event, option }; breadcrumbEmitter.emit(constants.EVENT_NAME.breadcrumbItemSelect, currentBreadcrumbItem); emit("select", currentBreadcrumbItem); if (!to || !router) { return; } replace ? router.replace(to) : router.push(to); }; export { linkClick };