Syntax error: unexpected token in uni app project compilation

Syntax error: unexpected token in uni app project compilation

Contents of articles

Syntax error: unexpected token error content error reason solution for uni app project compilation

Error content

Originally, it could run well. When it was pulled down and then run to wechat applet, it would report an error, but the web side could run normally~

Module build failed (from ./node_ modules/mini-css-extract-plugin/dist/ loader.js ):

The details are as follows:

Cause of error

None of the solutions found in the search work.

After a careful examination of the code, it is found that the & lt; script & gt; tag appears twice in a newly modified Vue file. The new one is used to describe the style,

Solution

The problem is solved by merging the content in the new & lt; script & gt; into the & lt; style & gt; tag

Note that there can only be three top-level tags in uni app!!

The root of the problem is that the team didn't communicate well, so there was a problem.. But uni app really has a lot of holes!!!!

Read More: