css深度选择器
在vue 項目中使用 scoped 后
在父組件中的樣式無法修改子組件的樣式這時可以使用深度作用選擇器 /deep/
例如:
<template><div id="chat"><el-input v-model="input" class="chat_input" placeholder="請輸入內容"></el-input></div> </template><script scoped?>.chat_input {/deep/ .el-input__inner {color:?#fff6f7}} </script>總結
- 上一篇: DDD专家张逸:复杂与架构演进的关系
- 下一篇: js笔记(7)