我正在使用 jquery 模板向 jquery Mobile 网站添加
最佳答案
jQM 文档:
Updating lists If you add items to a listview, you'll need to call the
refresh()
method on it to update the styles and create any nested lists that are added. For example:$('#mylist').listview('refresh');
Note that the
refresh()
method only affects new nodes appended to a list. This is done for performance reasons. Any list items already enhanced will be ignored by the refresh process. This means that if you change the contents or attributes on an already enhanced list item, these won't be reflected. If you want a list item to be updated, replace it with fresh markup before calling refresh.
关于插入 jquery 模板后,jquery mobile 不渲染列表,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8743931/