mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-24 12:19:20 +00:00
Put worker behind setting
This commit is contained in:
@@ -107,10 +107,15 @@ export class NotebookSerializer implements vscode.NotebookSerializer {
|
||||
data.metadata.indentAmount :
|
||||
' ';
|
||||
|
||||
return this.serializeViaWorker({
|
||||
notebookContent: sorted,
|
||||
indentAmount
|
||||
});
|
||||
const experimentalSave = vscode.workspace.getConfiguration('ipynb').get('experimental.serialization', false);
|
||||
if (experimentalSave) {
|
||||
return this.serializeViaWorker({
|
||||
notebookContent: sorted,
|
||||
indentAmount
|
||||
});
|
||||
} else {
|
||||
return Promise.resolve(JSON.stringify(sorted, undefined, indentAmount));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user