Skip to main content

Command Palette

Search for a command to run...

Vue3 use v-bind in style tag

Published
1 min read

Style

<script setup lang="ts">
const color = ref("red)
</script>

<style scoped>
.text {
    color: v-bind('color')
}
</style>
\n\n","author":{"@type":"Person","name":"0xBF","url":"https://hashnode.com/@0xbf","image":"https://cdn.hashnode.com/res/hashnode/image/upload/v1618853287211/v7dxYPp28.png"},"publisher":{"@type":"Organization","name":"0xBF","url":"https://hn.0xbf.me"},"datePublished":"2021-12-12T20:59:25.723Z","keywords":"Vue.js"}