mirror of
https://github.com/microsoft/monaco-editor.git
synced 2025-12-22 16:15:41 +01:00
Update printWidth to 100
This commit is contained in:
parent
365af6fa65
commit
c5586a25cf
24 changed files with 81 additions and 207 deletions
|
|
@ -5,23 +5,16 @@
|
|||
</head>
|
||||
<body>
|
||||
<h2>Monaco Diff Editor Sample</h2>
|
||||
<div
|
||||
id="container"
|
||||
style="width: 800px; height: 600px; border: 1px solid grey"
|
||||
></div>
|
||||
<div id="container" style="width: 800px; height: 600px; border: 1px solid grey"></div>
|
||||
|
||||
<script src="../node_modules/monaco-editor/min/vs/loader.js"></script>
|
||||
<script>
|
||||
require.config({ paths: { vs: '../node_modules/monaco-editor/min/vs' } });
|
||||
|
||||
require(['vs/editor/editor.main'], function () {
|
||||
var diffEditor = monaco.editor.createDiffEditor(
|
||||
document.getElementById('container')
|
||||
);
|
||||
var diffEditor = monaco.editor.createDiffEditor(document.getElementById('container'));
|
||||
|
||||
Promise.all([xhr('original.txt'), xhr('modified.txt')]).then(function (
|
||||
r
|
||||
) {
|
||||
Promise.all([xhr('original.txt'), xhr('modified.txt')]).then(function (r) {
|
||||
var originalTxt = r[0].responseText;
|
||||
var modifiedTxt = r[1].responseText;
|
||||
|
||||
|
|
@ -44,10 +37,7 @@
|
|||
}
|
||||
|
||||
if (req.readyState === 4) {
|
||||
if (
|
||||
(req.status >= 200 && req.status < 300) ||
|
||||
req.status === 1223
|
||||
) {
|
||||
if ((req.status >= 200 && req.status < 300) || req.status === 1223) {
|
||||
c(req);
|
||||
} else {
|
||||
e(req);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue