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

translate-plural not working with <translate> #122

Open
fjeddy opened this issue Dec 13, 2020 · 0 comments
Open

translate-plural not working with <translate> #122

fjeddy opened this issue Dec 13, 2020 · 0 comments

Comments

@fjeddy
Copy link

fjeddy commented Dec 13, 2020

Hello,

It seems like translate-plural doesn't work in combination with <translate>, the following code snippet, from your documentation, does not seem to work.

<translate :translate-n="cars" translate-plural="%{ count } cars">%{ count } car</translate> outputs count cars

while <li v-translate="{ count: cars }" translate-plural="%{count} cars" :translate-n="cars">%{count} car</li> works as expected.

Edit I realize now that this might be an underlying bug with count not being treated as it should. If I add the option translate-params, then it works correctly, which is the same thing I'm doing in the v-translate example, specifically defining count.

The following works

<translate :translate-n="cars" translate-plural="%{count} cars" :translate-params="{ count: cars }">%{ count } car</translate>
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