mirror of
https://github.com/microsoft/monaco-editor.git
synced 2025-12-22 11:35:40 +01:00
Fix line number API usage
This commit is contained in:
parent
e52655e468
commit
0b10139f53
2 changed files with 4 additions and 4 deletions
|
|
@ -44,7 +44,7 @@ var editor = monaco.editor.create(document.getElementById("container"), {
|
||||||
value: "// First line\nfunction hello() {\n\talert('Hello world!');\n}\n// Last line",
|
value: "// First line\nfunction hello() {\n\talert('Hello world!');\n}\n// Last line",
|
||||||
language: "javascript",
|
language: "javascript",
|
||||||
|
|
||||||
lineNumbers: false,
|
lineNumbers: "off",
|
||||||
roundedSelection: false,
|
roundedSelection: false,
|
||||||
scrollBeyondLastLine: false,
|
scrollBeyondLastLine: false,
|
||||||
readOnly: false,
|
readOnly: false,
|
||||||
|
|
@ -52,7 +52,7 @@ var editor = monaco.editor.create(document.getElementById("container"), {
|
||||||
});
|
});
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
editor.updateOptions({
|
editor.updateOptions({
|
||||||
lineNumbers: true
|
lineNumbers: "on"
|
||||||
});
|
});
|
||||||
}, 2000);
|
}, 2000);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ var editor = monaco.editor.create(document.getElementById("container"), {
|
||||||
value: "// First line\nfunction hello() {\n\talert('Hello world!');\n}\n// Last line",
|
value: "// First line\nfunction hello() {\n\talert('Hello world!');\n}\n// Last line",
|
||||||
language: "javascript",
|
language: "javascript",
|
||||||
|
|
||||||
lineNumbers: false,
|
lineNumbers: "off",
|
||||||
roundedSelection: false,
|
roundedSelection: false,
|
||||||
scrollBeyondLastLine: false,
|
scrollBeyondLastLine: false,
|
||||||
readOnly: false,
|
readOnly: false,
|
||||||
|
|
@ -14,6 +14,6 @@ var editor = monaco.editor.create(document.getElementById("container"), {
|
||||||
});
|
});
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
editor.updateOptions({
|
editor.updateOptions({
|
||||||
lineNumbers: true
|
lineNumbers: "on"
|
||||||
});
|
});
|
||||||
}, 2000);
|
}, 2000);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue