We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
vue/no-lifecycle-after-await
<script setup>
What rule do you want to change?
no-lifecycle-after-await
Does this change cause the rule to produce more or fewer warnings?
More warnings
How will the change be implemented? (New option, new default behavior, etc.)?
It will change the behavior of the existing I rule. I think no options should be necessary.
Please provide some example code that this change will affect:
<script setup> import { onMounted } from 'vue' /* ✓ GOOD */ onMounted(() => { /* ... */ }) await doSomething() /* ✗ BAD */ onMounted(() => { /* ... */ }) </script>
What does the rule currently do for this code?
There are no errors.
What will the rule do after it's changed?
The second onMounted will trigger an error
onMounted
Additional context
This rule currently works only when using a setup function.
<script> import { onMounted } from 'vue' export default { async setup() { /* ✓ GOOD */ onMounted(() => { /* ... */ }) await doSomething() /* ✗ BAD */ onMounted(() => { /* ... */ }) } } </script>
I think the fix would be similar to the one done for no-expose-after-wait. #1885
no-expose-after-wait
The text was updated successfully, but these errors were encountered:
vue/no-expose-after-await
See #1885 (comment)
Sorry, something went wrong.
No branches or pull requests
What rule do you want to change?
no-lifecycle-after-await
Does this change cause the rule to produce more or fewer warnings?
More warnings
How will the change be implemented? (New option, new default behavior, etc.)?
It will change the behavior of the existing I rule. I think no options should be necessary.
Please provide some example code that this change will affect:
What does the rule currently do for this code?
There are no errors.
What will the rule do after it's changed?
The second
onMounted
will trigger an errorAdditional context
This rule currently works only when using a setup function.
I think the fix would be similar to the one done for
no-expose-after-wait
. #1885The text was updated successfully, but these errors were encountered: