aboutsummaryrefslogtreecommitdiffstats
path: root/web/src/js/components/common
diff options
context:
space:
mode:
Diffstat (limited to 'web/src/js/components/common')
-rw-r--r--web/src/js/components/common/MonacoEditor.jsx34
1 files changed, 34 insertions, 0 deletions
diff --git a/web/src/js/components/common/MonacoEditor.jsx b/web/src/js/components/common/MonacoEditor.jsx
new file mode 100644
index 00000000..a0e8d58c
--- /dev/null
+++ b/web/src/js/components/common/MonacoEditor.jsx
@@ -0,0 +1,34 @@
+//not working
+import React, { Component, PropTypes } from 'react'
+
+export default class MonacoEditor extends Component {
+
+ constructor(props) {
+ super(props)
+ }
+
+ onLoad(){
+ window.MonacoEnvironment = {
+ getWorkerUrl: function(workerId, label) {
+ return 'worker-loader-proxy.js';
+ }
+ };
+ require.config({
+ paths: {
+ vs: '../release/min/vs'
+ }
+ });
+
+ }
+
+
+ render() {
+ return (
+ <div id="container"
+ ref={ref => this.editor = ref}
+ style="width:800px;height:600px;border:1px solid grey"
+ onLoad={this.onLoad()}>
+ </div>
+ )
+ }
+}