@intlify/vue-i18n/no-i18n-t-path-prop
disallow using
path
prop with<i18n-t>
- ✒️️ The
--fix
option on the command line can automatically fix some of the problems reported by this rule.
You cannot use path
prop with <i18n-t>
component. Perhaps it's an old habit mistake.
📖 Rule Details
This rule reports use of path
prop with <i18n-t>
component.
👎 Examples of incorrect code for this rule:
vue
<script>
/* eslint @intlify/vue-i18n/no-i18n-t-path-prop: 'error' */
</script>
<template>
<div class="app">
<!-- ✗ BAD -->
<i18n-t path="message.greeting" />
</div>
</template>
👍 Examples of correct code for this rule:
vue
<script>
/* eslint @intlify/vue-i18n/no-i18n-t-path-prop: 'error' */
</script>
<template>
<div class="app">
<!-- ✓ GOOD -->
<i18n-t keypath="message.greeting" />
<!-- ✓ GOOD -->
<i18n path="message.greeting" />
</div>
</template>
📚 Further reading
🚀 Version
This rule was introduced in @intlify/eslint-plugin-vue-i18n
v0.11.0