给v-bind属性指定一个对象的名字

<script>
export default {
  data() {
    return {
      css: {class:'wrapper',id:'div1'}
      
    }
  }
}
</script>

<template>
<div v-bind="css">this is a div</div>
</template>

<style scoped>
button {
  font-weight: bold;
}

.wrapper {
    background-color: rgb(64, 255, 0);
}
</style>