我正在 Meteor 开发一个大型企业应用程序。我遇到的问题是,一旦我的 html 页面长度超过 900 多行,我就会开始偶尔(更常见的是使用更多代码行)收到以下错误:
Your app is crashing. Here's the latest log.
Errors prevented startup:
Exception while bundling application:
Error: unclosed <body> - line 7, file /var/www/www.######.com/#######.html
<body>
at new html_scanner.scan.parseError (/usr/lib/meteor/packages/templating/html_scanner.js:23:14)
at Object.html_scanner.scan (/usr/lib/meteor/packages/templating/html_scanner.js:92:15)
at /usr/lib/meteor/packages/templating/package.js:46:32
at _.extend.add_file (/usr/lib/meteor/app/lib/bundler.js:195:5)
at self.api.add_files (/usr/lib/meteor/app/lib/bundler.js:96:16)
at Array.forEach (native)
at Function._.each._.forEach (/usr/lib/meteor/app/lib/third/underscore.js:79:11)
at self.api.add_files (/usr/lib/meteor/app/lib/bundler.js:95:11)
at Array.forEach (native)
at Function._.each._.forEach (/usr/lib/meteor/app/lib/third/underscore.js:79:11)
Your application is crashing. Waiting for file change.
如果我多次刷新我的页面,它最终会起作用,并且我知道没有未关闭的标签。我已经通过几个 html lint 程序运行了 html,没有任何错误。我的代码是专有的,所以我不能发布它,但想知道其他人遇到过这个问题吗?
我想知道 html_scanner 是否有问题,但没有时间调试模板包。任何想法将不胜感激。