Home > Web Front-end > JS Tutorial > body text

How to deal with the blank display after vue is packaged

小云云
Release: 2018-01-19 14:46:59
Original
2666 people have browsed it

In projects, it is often necessary to use vue to package it into html for browsing without placing it on the server. According to the html packaged from the official website, it displays blank when opened directly. Many friends have encountered such a problem. When vue is packaged, it displays a blank problem. How to deal with such a problem? Below, the editor of Script House will share with you the correct way to deal with the blank display after Vue is packaged. Friends who are interested should take a look at it. I hope it can help everyone.

The correct way to handle the blank display after vue is packaged is

1. Find the configuration file

Modify

This way the packaging process can be opened but the page style will not be found

2. Modify

Find the corresponding location and add publicPath: '../../' and then it works!

Many friends have also encountered this problem. After vue is packaged, the index file is blank. What's going on?

After you package the vue project with npm run build, click on the index file to open a blank page,

and report an error. Solution: path problem,

Related recommendations:

Vue.js project packaging and online graphic explanation

Detailed explanation of batch downloading and packaging of files in Vue

Detailed explanation of webpack multi-entry file page packaging

The above is the detailed content of How to deal with the blank display after vue is packaged. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template