Hi,
I have a small test project, I just wanted to test if angular and vaadin 10 frontend can work together.
I have basically good results, but I could not make the grid work:
I have in my controller ts file (this is coming from the vaading-grid html examples, from the official documentation):
users = [
{“name”: “John”, “surname”: “Lennon”, “role”: “singer”},
{“name”: “Ringo”, “surname”: “Starr”, “role”: “drums”}
];
in my html file I have:
<vaadin-grid items='{{users}}'>
<vaadin-grid-column>
<template class="header">Index</template>
<template>[[index]
]
Name
[[item.name]
]
Surname
[[item.surname]
]
Role
[[item.role]
]
The grid shows, but it’s empty, if I use the code exactly from the sample page:
<vaadin-grid items='[{"name": "John", "surname": "Lennon", "role": "singer"},{"name": "Ringo", "surname": "Starr", "role": "drums"}]
'>
Index
[[index]
]
Name
[[item.name]
]
Surname
[[item.surname]
]
Role
[[item.role]
]
Then it works.
I tried a lot of different things, but I could not make it work. What is the correct way, to feed items to the vaadin-grid from angular?
Thank you very much!