Permalink
Browse files

first commit

  • Loading branch information...
s2terminal committed Apr 15, 2018
1 parent 21093d8 commit ed4d045f1129b70cf98ea821ee167783313d4c10
Showing with 45 additions and 0 deletions.
  1. +1 −0 .gitignore
  2. +17 −0 index.html
  3. +5 −0 main.css
  4. +11 −0 main.js
  5. +11 −0 package-lock.json
View
@@ -0,0 +1 @@
node_modules/
View
@@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Page Title</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="main.css" />
<script src="node_modules/monaco-editor/min/vs/loader.js"></script>
<script src="main.js"></script>
</head>
<body>
<div id="container"></div>
</body>
</html>
View
@@ -0,0 +1,5 @@
#container{
width:800px;
height:600px;
border:1px solid grey;
}
View
11 main.js
@@ -0,0 +1,11 @@
require.config({ paths: { 'vs': 'node_modules/monaco-editor/min/vs' }});
require(['vs/editor/editor.main'], function() {
var editor = monaco.editor.create(document.getElementById('container'), {
value: [
'function x() {',
'\tconsole.log("Hello world!");',
'}'
].join('\n'),
language: 'javascript'
});
});
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

0 comments on commit ed4d045

Please sign in to comment.