[Vuejs]-Is there a way to use newline characters in vue.js

1๐Ÿ‘

โœ…

Yes. You can use <br> (HTML code) instead of \n.

And in the HTML use it this way:

<div v-html="text">

[Edit]

Please see the following fiddle.

-1๐Ÿ‘

try this:

text: "Button\ 3"

ust enter a back-slash and keep on โ€“ hopefully this works now!

Leave a comment