Axios Json-Array - Error


i have a mysql-DB, a php file for reading tables and axios to get the response.

data: () => ({
users: [],
userid: 0

With the following code:
axios.get(“ajaxfile.php”).then(function(response) {


i get this result:


But i cant do it to transform in the variable “users”… i try " but i doesnt work…

this is my table i will show the data…


  <tr v-for="user in users" :key="">
    <td>{{ user.username }}</td>
    <td>{{ }}</td>
    <td>{{ }}</td>

What am I doing wrong? JSON.parse says it has invalid chars… (the brackets…)



Hey @Jakan, I ran a quick test on your output and I found the following:

Which means they are actually separated into 2 separate objects, if you want to assign the to your this.user variable, you will need to access one of these objects by the following:[0] or[1]


thanks for your reply.

if i make[1] it is only the first sign in the json-Response (the bracket) --> “[”