From 1f50f977571ce8d39a53d88e7f9ee6a19030485f Mon Sep 17 00:00:00 2001 From: Onoshko Dan Date: Fri, 18 Apr 2014 14:14:54 +0700 Subject: [PATCH] Demo code by default --- lib/index.html | 37 +++++++++++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/lib/index.html b/lib/index.html index 22cbd656..ebceaad7 100644 --- a/lib/index.html +++ b/lib/index.html @@ -44,7 +44,38 @@ - +
@@ -55,7 +86,9 @@ resultArea = document.getElementById("result"), isjs = document.getElementById("is_js"), source; - sourceArea.value = source = localStorage.source; + + if(!localStorage.source) localStorage.source = source = sourceArea.value; + else sourceArea.value = source = localStorage.source; isjs.checked = localStorage.isjs == "t"; function compile(){