@lark-apaas/devtool-kits 1.0.1 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/error.html +4 -9
- package/package.json +1 -1
package/dist/error.html
CHANGED
|
@@ -132,27 +132,22 @@
|
|
|
132
132
|
let errorData = {
|
|
133
133
|
message: `{{.errorData.message}}`,
|
|
134
134
|
};
|
|
135
|
-
let locationData = null;
|
|
136
|
-
|
|
137
135
|
// 初始化页面
|
|
138
136
|
function init() {
|
|
139
137
|
// 绑定事件
|
|
140
138
|
document.getElementById('copyBtn').addEventListener('click', handleCopy);
|
|
141
139
|
document.getElementById('repairBtn').addEventListener('click', handleRepair);
|
|
142
140
|
|
|
143
|
-
//
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
hash: window.location.hash,
|
|
148
|
-
};
|
|
141
|
+
// 通知前端,渲染错误页面已准备就绪
|
|
142
|
+
sendPostMessage({
|
|
143
|
+
type: 'PreviewReady'
|
|
144
|
+
});
|
|
149
145
|
|
|
150
146
|
// 如果有错误对象,发送 postMessage
|
|
151
147
|
if (errorData) {
|
|
152
148
|
sendPostMessage({
|
|
153
149
|
type: 'RenderError',
|
|
154
150
|
data: errorData,
|
|
155
|
-
location: locationData,
|
|
156
151
|
});
|
|
157
152
|
}
|
|
158
153
|
}
|