     @$form = $("#editor-container form")
     @$saveCodeButton = @$form.find("[type=submit]")
 
-    @editor.on "change", => @updatePreview()
+    @editor.on "change", => @debouncedUpdatePreview()
 
     @$form.submit (event) =>
 


class LevelCreator

  plugins : []
  stack : null
  canvas : null

      ).done =>
        @prepareHeadlessRendering()


  debouncedUpdatePreview : ->

    @debouncedUpdatePreview = _.debounce(@updatePreview, @EDIT_DEBOUNCE_TIME)    


  updatePreview : ->

