使用 VUE 应用程序去除主页上的细白边框

Gir*_* BN 1 css webpage vue.js vuejs2

你好 Vue/css 专家,

我是 VUE 的新手,我现在正在努力学习,使用我开发的所有 VUE 应用程序,页面顶部和左侧似乎有一个细小的白色边框,当我有一个黑暗的时候它变得很烦人背景。有什么办法可以消除吗??

下面是代码

<!-- main.js-->  
import Vue from 'vue'
import App from './App.vue'

new Vue({
  el: '#app',
  render: h => h(App)
})


<!-- App.vue-->
<template>
  <div id="app" class="initial">
      <router-view class='initial'></router-view>
    </div>
</template>

<script>
import axios from "axios";
import Cookies from "js-cookie";
export default {
  name: "app",
  mounted() {}
};
</script>
<style>
.initial {
  background-size: cover;
  background: linear-gradient(
    to bottom,
    rgb(98, 208, 223) 0%,
    rgb(7, 65, 73) 100%
  );
  position: absolute;
  width: 100%;
  height: 100%;
}
</style>
Run Code Online (Sandbox Code Playgroud)

下面是浏览器页面的图像,其中有一个细小的白色间隙。

基本上背景没有覆盖整个浏览器页面

背景

甚至默认出现滚动条,我需要在这里更改什么,只是为了填充整个背景而不使用滚动条

谢谢

the*_*kid 5

这是默认的边距。您可以通过将下面给定的 css 放在样式表的开头来修复它。

 * {
       margin: 0;
   }
Run Code Online (Sandbox Code Playgroud)

PS * - 选择所有元素。