diff --git a/web/index.js b/web/index.js index a823c88..e82c2a3 100644 --- a/web/index.js +++ b/web/index.js @@ -5,6 +5,21 @@ var editor = CodeMirror.fromTextArea(document.getElementById("codeInput"), { mode: "javascript" }); editor.setSize("100%", height); +editor.setValue(`option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [150, 230, 224, 218, 135, 147, 260], + type: 'line' + } + ] +};`); function run() { var option = editor.getValue();