Several ways to introduce css in vue

1. Introduce in main.js

import 'common/stylus/index.styl'

or

import '@/common/stylus/index.styl'

2. In the .vue file

@import '../../common/stylus/mixin.styl';

3. Introduce in index.html

Note:
1. In the index.js under the config directory, the static resource path that index.html needs to be referenced is explained
. 2. It must be placed under the static directory to be referenced

Insert picture description here
Quote

<link rel="stylesheet" href="./static/css/reset.css"/>

Insert picture description here

Guess you like

Origin blog.csdn.net/weixin_42645716/article/details/112968186