Skip to content

Global CSS medium #CSS Features

By webfansplz @webfansplz

Take the Challenge    简体中文

Sometimes, we may want to set global CSS in the scoped component. Do you know how to solve it?. Lets go 👇:

<template>
  <p>Hello Vue.js</p>
</template>

<style scoped>

p {
  font-size:20px;
  color:red;
  text-align: center;
  line-height: 50px;
}

/* Make it work */
body {
  width: 100vw;
  height: 100vh;
  background-color: burlywood;
}
</style>

Share your Solutions Check out Solutions