Skip to content
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

Button vue Component - props are not reactive #87

Open
roolian opened this issue May 7, 2024 · 0 comments
Open

Button vue Component - props are not reactive #87

roolian opened this issue May 7, 2024 · 0 comments

Comments

@roolian
Copy link

roolian commented May 7, 2024

Issue

The Button component props are not reactive.

<Button :leftIcon="ListBulletIcon" as="button" @click="displayGrid=false" :variant="displayGrid ? 'outline' : 'solid'" :color="displayGrid ? 'secondary' : 'success'">
   Liste
 </Button>

Inside component, props.variant change but not mergedProps.variant.

Solution

This change fix the issue.
Remove "computed" import

import { computed } from "@vue/reactivity";

Import "computed" from "vue"

import { inject, computed } from "vue";

@roolian roolian changed the title Button vue Component Button vue Component - props are not reactive May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant