父组件中为子组件设置的样式优先级较高
子组件样式
<div class="div">
</div>
.div{
width: 100px;
height: 100px;
background: deepskyblue;
}
父组件中,再次为子组件设置样式
<swiper-test style="width: 200px;height: 200px;background: black"></swiper-test>
子组件样式显示效果为父组件设置的样式