#  css  怎样排除第一个元素给其他元素设置样式
在 css  中可以利用 “:first-child”  选择器和 “:not”  选择器来设置除了第一个元素其他元素的样式。
:first-child  选择器用于选取属于其父元素的首个子元素的指定选择器。
:not(selector)  选择器匹配非指定元素 / 选择器的每个元素。
| 12
 3
 
 | .select_btn:not(:first-child) {padding-left: 90px;
 }
 
 | 
#  vue script  结构
| 12
 3
 4
 5
 6
 7
 8
 9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 
 | <script>export default {
 name: "Home",
 data() {
 return {};
 },
 methods: {
 
 },
 watch: {
 
 },
 computed: {
 
 },
 beforeCreate: function() {
 
 },
 created: function() {
 
 },
 beforeMount: function() {
 
 },
 mounted: function() {
 
 
 
 console.log("Home done");
 },
 beforeUpdate: function() {
 
 },
 updated: function() {
 
 
 
 },
 beforeDestroy: function() {
 
 },
 destroyed: function() {
 
 }
 };
 </script>
 
 | 
#  vue  监听数据变化  watch
| 12
 3
 4
 5
 6
 7
 8
 9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 
 | <script>export default {
 name: "app",
 data(){
 return {
 inputValue: '',
 passedInputValue: ''
 }
 },
 watch:{
 inputValue() {
 
 setTimeout(() => {
 this.passedInputValue = this.inputValue;
 }, 3000)
 }
 }
 };
 </script>
 
 | 
获取变化之前的值:
| 12
 3
 4
 5
 6
 7
 
 | watch:{inputValue(value,oldValue) {
 
 console.log(`新值:${value}`);
 console.log(`旧值:${oldValue}`);
 }
 }
 
 | 
#  Vue  中显示与隐藏
v-show
| 1
 | <div class="panel_all" v-show="select_app_show"></div>
 | 
#  v-for  使用
| 1
 | <a v-for="(item,index) in items" v-on:click="onclick(index)" href="javascript:void(0)">{{ index }}{{ item.text }}</a>
 |