Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
{context => (
<a href="{to}"> context.onSelect(e, groupId, itemId, to, preventDefault, onClick)}
className={css(styles.navLink, isActive && styles.modifiers.current, className)}
aria-current={isActive ? 'page' : null}
{...rest}
>
{children}
</a>
)}
{context =>
React.cloneElement(children, {
onClick: e => context.onSelect(e, groupId, itemId, to, preventDefault, onClick),
className: css(styles.navLink, isActive && styles.modifiers.current, className),
'aria-current': isActive ? 'page' : null
})
}