We will learn how to convert string to array using split() in vue js.


<!DOCTYPE html>
    <title>Vue JS Convert String to Array | Vue JS Split String Example - rathorji.in</title>
    <script src="https://cdn.jsdelivr.net/npm/vue"></script>
<div id="app">
  <p>String : {{ myString }}</p>
  <p>Array : {{myResult}}</p>
  <button @click="clickFunction()">Click Me</button>
<script type="text/javascript">
    var app = new Vue({
      el: '#app',
      data: {
        myString: "This is rathorji.in" ,
        myResult: ''
        clickFunction: function () {   
            this.myResult = this.myString.split(" ");

I hope this helped you..