You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|**code**|`string` <br /><br /> The current code in the Monaco editor. This value updates on change to the Monaco editor with optional debouncing. Alias for `sandbox.getText()`|
88
-
|**setCode**| `(code: string, options: {format: "prettier" | "monaco"}) => void` <br /><br /> Set the code in the Monaco editor with optional formatting with Prettier or Monaco. Alias for `sandbox.setText()` |
88
+
|**setCode**| `(code: string, options: {format: \"prettier\"|\"monaco\"}) => void` <br /><br /> Set the code in the Monaco editor with optional formatting with Prettier or Monaco. Alias for `sandbox.setText()` |
89
89
|**formatCode**|`() => void` <br /><br /> Format the code in the Monaco editor. Alias for `sandbox.editor.getAction("editor.action.formatDocument").run()`|
90
-
| **prettier** | `prettier(config?: Options) => string` <br /><br /> Format the code in the Monaco editor with prettier. Accepts a prettier config object.
90
+
| **prettier** | `prettier(config?: Options) => string` <br /><br /> Format the code in the Monaco editor with Prettier. Accepts a Prettier config object.
91
91
|**markers**|`(IMarker & {key: string})[]` <br /><br /> Alias for `sandbox.monaco.editor.getModelMarkers({})` with added unique `key` property. Kept in sync via `sandbox.editor.onDidChangeModelDecorations`. |
92
92
|**setDebounce**|`(debounce: boolean) => void` <br /><br /> Optionally debounce the `modelChange` event from the Plugin API. |
93
93
|**sandbox**|`object` <br /><br /> A DOM library for interacting with TypeScript and JavaScript code, which powers the heart of the TypeScript playground. This object provides several properties and methods to interact with the playground. See all of the available types in `src/plugin/vendor/sandbox.d.ts` and read more about the sandbox at [http://www.typescriptlang.org/v2/dev/sandbox/](http://www.typescriptlang.org/v2/dev/sandbox/). |
0 commit comments