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

Fix SinglePageLayout Vue warnings #11

Merged
merged 1 commit into from
Nov 14, 2024
Merged

Conversation

MattTheCuber
Copy link
Contributor

@MattTheCuber MattTheCuber commented Nov 14, 2024

Fixes the following warnings:

Warning: A Vue directive is evaluating your expression and trame would expect a tuple instead of a plain type. <template v-slot:activator="{ props }" ... />
Warning: A Vue directive is evaluating your expression and trame would expect a tuple instead of a plain type. <VIcon v-bind="props" ... />
Warning: A Vue directive is evaluating your expression and trame would expect a tuple instead of a plain type. <template v-slot:activator="{ props }" ... />
Warning: A Vue directive is evaluating your expression and trame would expect a tuple instead of a plain type. <VIcon v-bind="props" ... />

@snacksbro
Copy link

30

@ConnorNoddin
Copy link

Did you run the standard test suite?

Copy link

@vmiller987 vmiller987 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks excellent. Thank you for this.
9/10/10

@MattTheCuber
Copy link
Contributor Author

Did you run the standard test suite?

I believe this repository has an automated testing workflow that will be run.

@ConnorNoddin
Copy link

Did you run the standard test suite?

I believe this repository has an automated testing workflow that will be run.

Excellent. Approved! Thanks for contributing to this great project

@jourdain
Copy link
Collaborator

I would not change those since they are directives but for beginners it is good to be aware of it.

@MattTheCuber
Copy link
Contributor Author

Do you have a suggestion on another way to fix the warnings?

@jourdain
Copy link
Collaborator

We could remove the warning on the directive. But those are only display when you run with --debug. Is that an issue?

@MattTheCuber
Copy link
Contributor Author

I thought the warnings were indicating that you should be using a tuple? Every time we find these warnings, we use this solution to resolve them.

@jourdain
Copy link
Collaborator

The idea is to be explicit and coherent with the trame syntax. But as long as you trully understand how directive works, then skipping the tuple give you a more compact syntax. Also, providing the default value tends to force you to use a tuple in your code, which is indeed good. But for that "fixed" template, there is no point to provide a default.

@jourdain
Copy link
Collaborator

but since it is at the layout level, to prevent confusion, I think I would be ok to merge that. I'm just saying that if that was my code in an app, I would not want to change it. ;-)

@jourdain jourdain merged commit 9b4cb32 into Kitware:master Nov 14, 2024
6 checks passed
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

Successfully merging this pull request may close these issues.

5 participants