Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UTF-8 encoding in a v-for

Tags:

vue.js

i'm trying to list all product from my databse. All my page is display well but for my list the UTF-8 encoding doesn't seems to work. I'm french so i use some "é è ê".. So when i'm doing something like <div class ="notrelevent"> Général </div>

it works great but when i do something like

`<tr v-for="product in products | paginate" :product="product"></tr>    `

I have bad result like : this is a test � again cr�me

Or i should get :

this is a test à again crème

Thanks for the help

like image 466
Sylvain Attoumani Avatar asked Sep 03 '25 02:09

Sylvain Attoumani


1 Answers

1) In your HTML section, you should put this:

<meta charset="utf-8">

2) Any database call should be done with a client using utf8.

like image 144
Gabriel Robert Avatar answered Sep 05 '25 23:09

Gabriel Robert