在vue项目的根目录下创建vue.config.js目录(如果没有) module.exports = { lintOnSave: false //加入此行 , false为关闭true为开启 } 加入之后,重启项目就可以了