Thanks @munsterlander, I’ll try that approach.
uhunkler
@uhunkler
Posts made by uhunkler
-
RE: How to react to the event of ons-list with »tappable« ons-list-items?
-
RE: Fill list with new items on button click.
@Fran-Diox, @munsterlander, thanks a lot for your valuable feedback, the links are very helpful. Looking at the To-do app I found answers to some questions I hadn’t asked yet.
-
How to react to the event of ons-list with »tappable« ons-list-items?
When I have an ons-list with »tappable« ons-list-items how can I react to the event which is sent by the item on tap? I didn’t find an example. Do I need to add »onclick« or can I use an event listener. To what event should that be bound?
Thanks for you answers.
Urs -
RE: Fill list with new items on button click.
@Fran-Diox Thanks for your answer.
The task is to display the list of paired bluetooth devices. I need to fetch them via the Cordova plugin «cordova-plugin-bluetooth-serial» and show them in a list. And offer a button to refresh the list.
When I read your answer correct, you propose to not use ons-list at all but a normal HTML list. I was hoping to be able to use the ons-list to get a consistent list styling.
Are there classes that I can use with HTML tags to get that same styling as the ons-* tags?
-
Fill list with new items on button click.
I am doing my fist steps to evaluate Onsen UI 2.0. I want to create mobile interfaces for IoT/robotic projects and look for a convenient environment to create the UI for those projects.
I am not sure if my approach to fill a list with new items on button click is correct. Because I didn’t find an example I tried with
<ons-lazy-repeat id="dynamic-list"></ons-lazy-repeat>
.Please have a look at the codepen Onsen UI dynamic list which somehow solves the task.
- Is this the best approach or is there a better way to solve the task?
- How can the template be used for
createItemContent: function(index, template)
? - How can the actual data be integrated into the template?
Thanks a lot for your answers.
Urs