Skip to content

Cannot use "to" attribute in CLink Component #177

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
kanemotos opened this issue Dec 3, 2021 · 2 comments
Closed

Cannot use "to" attribute in CLink Component #177

kanemotos opened this issue Dec 3, 2021 · 2 comments

Comments

@kanemotos
Copy link

CLink's "to" attribute seems not to be implemented.

The "to" attribute is not available for all components that inherit from CLink.

Vue version: 3.2.23
@coreui/vue version: 4.1.0

Thanks.

@mrholek
Copy link
Member

mrholek commented Dec 6, 2021

In v4 we don't use vue-router. But you can add it manually and use to attribute

<router-link
  to="/about"
  custom
  v-slot="{ href, route, navigate, isActive, isExactActive }"
>
  <CLink :active="isActive" :href="href" @click="navigate"
    >{{ route.fullPath }}</NavLink
  >
</router-link>

@github-actions
Copy link

github-actions bot commented Feb 4, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants