Comments (4)
背景
1、List-item 在 Component2 【开启】的状态下,往数组中添加新数据会出现页面渲染失败问题。 2、From 表单在 Component2 【未开启】的状态下,会出现name绑定属性中的属性找不到。
期望
List-item 能追加新数据,并且不会出现页面渲染失败问题
思路
我也遇到问题1,同开启了Component2及push进数组
af-appx.worker.min.js:26 worker render components is not sync! can not find id from path: 1-2-2-2:/node_modules/antd-mini/es/List/ListItem/index
Please check your axml:
in /node_modules/antd-mini/es/List/ListItem/index
in view
in view
in /node_modules/antd-mini/es/List/index
in view
in view
InputItem也是一样的问题
orker render components is not sync! can not find id from path: 1-2-3:/node_modules/antd-mini/es/InputItem/index
Please check your axml:
in /node_modules/antd-mini/es/InputItem/index
in view
in view
in view
from ant-design-mini.
背景
1、List-item 在 Component2 【开启】的状态下,往数组中添加新数据会出现页面渲染失败问题。 2、From 表单在 Component2 【未开启】的状态下,会出现name绑定属性中的属性找不到。
期望
List-item 能追加新数据,并且不会出现页面渲染失败问题
思路
我也遇到问题1,同开启了Component2及push进数组
af-appx.worker.min.js:26 worker render components is not sync! can not find id from path: 1-2-2-2:/node_modules/antd-mini/es/List/ListItem/index Please check your axml: in /node_modules/antd-mini/es/List/ListItem/index in view in view in /node_modules/antd-mini/es/List/index in view in view
InputItem也是一样的问题
orker render components is not sync! can not find id from path: 1-2-3:/node_modules/antd-mini/es/InputItem/index Please check your axml: in /node_modules/antd-mini/es/InputItem/index in view in view in view
原来是setData
导致的问题
handleAddItem(){
let _list = this.data.list;
let nextId =_list.length;
let defaultItem = {id: (nextId+1), title:'new Item'+ (nextId+1), content:''};
_list.push(defaultItem);
this.setData({list : _list}); // 这里导致的
console.log('handleAddObject', this.data.list)
},
改成以下就能跑了:
handleAddItem(){
let _list = this.data.list;
let nextId =_list.length;
let defaultItem = {id: (nextId+1), title:'new Item' + (nextId+1), content:''};
this.setData({
['list['+ nextId +']'] : defaultItem // 改成这种写法就可以跑了
})
},
from ant-design-mini.
https://mini.ant.design/components/form
from ant-design-mini.
from ant-design-mini.
Related Issues (20)
- 手机端适配问题
- form的onValuesChange监听 HOT 4
- from表单的监听方法onValueChange赋值问题
- 纵向的tabs的scroll-view容器可以支持透传scroll-top、scroll-into-view等属性吗 HOT 3
- swipe-action滑动组件 HOT 1
- Popup组件目前只支持上下左右弹出,希望可以可以支持从中间弹出 HOT 1
- 日历组件需求征集 HOT 1
- form表单input框样式问题 HOT 1
- 希望avatar组件增加Icon和及字符类型
- 希望兼容一下微信小程序,虽然有点过分,但是这个需求很迫切呀 HOT 3
- antd-mini在小程序插件内报错:【插件公开组件的 acss 文件不支持使用 "元素选择器"】 HOT 2
- form-textarea HOT 1
- anti-mini组件 可供输入的下拉框 HOT 1
- 使用new form时 报错需要使用 component2 HOT 2
- 钉钉小程序 通过 dd.navigateTo跳转页面第二次报错,请问怎么解决呢 HOT 6
- input 的 type 设置 number 无效 HOT 3
- textarea 使用 onConfirm后无法清空输入的内容 HOT 4
- 如何在 input 设置了 disabled=true 时,修改 input 的字体样式 ? HOT 2
- popup组件关闭时,蒙层会闪屏 HOT 2
- popup 内的 picker-view 异常 HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ant-design-mini.