fluidcad 0.0.13 → 0.0.14
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/package.json +1 -1
- package/server/dist/index.js +23 -15
package/package.json
CHANGED
package/server/dist/index.js
CHANGED
|
@@ -174,22 +174,30 @@ async function handleExtensionMessage(msg) {
|
|
|
174
174
|
broadcastToUI({ type: 'processing-file' });
|
|
175
175
|
currentFile = msg.fileName;
|
|
176
176
|
}
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
177
|
+
try {
|
|
178
|
+
const data = await fluidCadServer.updateLiveCode(msg.fileName, msg.code);
|
|
179
|
+
if (myVersion !== renderVersion) {
|
|
180
|
+
return;
|
|
181
|
+
}
|
|
182
|
+
if (data) {
|
|
183
|
+
sendToExtension({
|
|
184
|
+
type: 'scene-rendered',
|
|
185
|
+
absPath: data.absPath,
|
|
186
|
+
result: data.result,
|
|
187
|
+
rollbackStop: data.rollbackStop,
|
|
188
|
+
});
|
|
189
|
+
broadcastToUI({
|
|
190
|
+
type: 'scene-rendered',
|
|
191
|
+
result: data.result,
|
|
192
|
+
absPath: data.absPath,
|
|
193
|
+
});
|
|
194
|
+
}
|
|
180
195
|
}
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
rollbackStop: data.rollbackStop,
|
|
187
|
-
});
|
|
188
|
-
broadcastToUI({
|
|
189
|
-
type: 'scene-rendered',
|
|
190
|
-
result: data.result,
|
|
191
|
-
absPath: data.absPath,
|
|
192
|
-
});
|
|
196
|
+
catch {
|
|
197
|
+
// Silently ignore errors during live-update (syntax errors, incomplete
|
|
198
|
+
// expressions, etc. while the user is typing). The last successful
|
|
199
|
+
// render remains visible. Model-building errors are delivered separately
|
|
200
|
+
// via scene-rendered object properties and are not affected.
|
|
193
201
|
}
|
|
194
202
|
break;
|
|
195
203
|
}
|