0👍
According to docs you should be able to access variable in style
tags not in javascript.
<template>
<div>
<h1>Hello world</h1>
</div>
</template>
<script>
export default {
mounted(){
}
}
</script>
<style lang="scss">
div h1 {
background-color: $primary;
}
</style>
- [Vuejs]-Upload Media files to MongoDB from Node.js server
- [Vuejs]-Use returned object from laravel controller in vue template
Source:stackexchange.com