devjin0617 / vue2-admin-lte

:bar_chart: adminLTE to vuejs v2.x converting project
https://devjin0617.github.io/vue2-admin-lte
MIT License
1.07k stars 323 forks source link

An error occurred using modal.vue #68

Open nckf opened 4 years ago

nckf commented 4 years ago

I tried to use App.vue in my larva 6 project

ERROR in ./node_modules/vue2-admin-lte/src/components/Modal.vue?vue&type=template&id=796e3219&lang=html& (./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/html-loader!./node_modules/vue-loader/lib??vue-loader-options!./node_modules/vue2-admin-lte/src/components/Modal.vue?vue&type=template&id=796e3219&lang=html&)
Module Error (from ./node_modules/vue-loader/lib/loaders/templateLoader.js):
(Emitted value instead of an instance of Error)
  Errors compiling template:
  text "module.exports = "\n" outside root element will be ignored.
......

open the Model.vue

change the first row

<template lang="html">

to

<template>

run... the trouble was solved.

How did the trouble come about?Is there a better way than changing files?

I'm sorry, I can't speak English