瀏覽代碼

Add comment explaining lint errors vs compile log errors

Alasdair Smith 9 年之前
父節點
當前提交
9cde236bc8
共有 1 個文件被更改,包括 4 次插入 和 0 次删除
  1. 4 0
      services/web/public/coffee/ide/editor/directives/aceEditor.coffee

+ 4 - 0
services/web/public/coffee/ide/editor/directives/aceEditor.coffee

@@ -376,6 +376,10 @@ define [
 
 					$rootScope.hasLintingError = false
 					session.on('changeAnnotation', () ->
+						# Both linter errors and compile logs are set as error annotations,
+						# however when the user types something, the compile logs are
+						# replaced with linter errors. When we check for lint errors before
+						# autocompile we are guaranteed to get linter errors
 						hasErrors = session
 							.getAnnotations()
 							.filter((annotation) -> annotation.type == 'error')