(data)
| 10654 | // merge static and dynamic style data on the same vnode |
| 10655 | //在同一个vnode上合并静态和动态样式数据 |
| 10656 | function normalizeStyleData(data) { |
| 10657 | // //将可能的数组/字符串值规范化为对象 把style 字符串 转换成对象 比如'width:100px;height:200px;' 转化成 {width:100px,height:200px} 返回该字符串。 |
| 10658 | var style = normalizeStyleBinding(data.style); //获取到vonde中的style属性值 |
| 10659 | // static style is pre-processed into an object during compilation |
| 10660 | // and is always a fresh object, so it's safe to merge into it |
| 10661 | //静态样式在编译期间被预处理为对象 |
| 10662 | //始终是一个新鲜的对象,所以可以安全地融入其中 |
| 10663 | return data.staticStyle ? |
| 10664 | extend(data.staticStyle, style) : //合并静态 |
| 10665 | style |
| 10666 | } |
| 10667 | |
| 10668 | // normalize possible array / string values into Object |
| 10669 | //将可能的数组/字符串值规范化为对象 |
no test coverage detected