DEV: apply coding standards (#109)

DEV: apply coding standards (#109)

diff --git a/.eslintrc b/.eslintrc
index 86ed71b..7898fbf 100644
--- a/.eslintrc
+++ b/.eslintrc
@@ -1,93 +1,3 @@
 {
-  "env": {
-    "jasmine": true,
-    "node": true,
-    "mocha": true,
-    "browser": true,
-    "builtin": true
-  },
-  "parserOptions": {
-    "ecmaVersion": 7,
-    "sourceType": "module"
-  },
-  "globals": {
-    "Ember": true,
-    "jQuery": true,
-    "$": true,
-    "QUnit": true,
-    "RSVP": true,
-    "Discourse": true,
-    "Handlebars": true,
-    "I18n": true,
-    "bootbox": true,
-    "moduleFor": true,
-    "moduleForComponent": true,
-    "Pretender": true,
-    "sandbox": true,
-    "controllerFor": true,
-    "test": true,
-    "visit": true,
-    "andThen": true,
-    "click": true,
-    "currentPath": true,
-    "currentRouteName": true,
-    "currentURL": true,
-    "fillIn": true,
-    "keyEvent": true,
-    "triggerEvent": true,
-    "count": true,
-    "exists": true,
-    "visible": true,
-    "invisible": true,
-    "asyncRender": true,
-    "asyncTestDiscourse": true,
-    "fixture": true,
-    "find": true,
-    "sinon": true,
-    "moment": true,
-    "_": true,
-    "alert": true,
-    "define": true,
-    "require": true,
-    "requirejs": true,
-    "hasModule": true,
-    "Blob": true,
-    "File": true
-  },
-  "rules": {
-    "block-scoped-var": 2,
-    "dot-notation": 0,
-    "eqeqeq": [2, "allow-null"],
-    "guard-for-in": 2,
-    "no-bitwise": 2,
-    "no-caller": 2,
-    "no-cond-assign": 0,
-    "no-debugger": 2,
-    "no-empty": 0,
-    "no-eval": 2,
-    "no-extend-native": 2,
-    "no-extra-parens": 0,
-    "no-inner-declarations": 2,
-    "no-irregular-whitespace": 2,
-    "no-iterator": 2,
-    "no-loop-func": 2,
-    "no-multi-str": 2,
-    "no-new": 2,
-    "no-plusplus": 0,
-    "no-proto": 2,
-    "no-script-url": 2,
-    "no-sequences": 2,
-    "no-shadow": 2,
-    "no-undef": 2,
-    "no-unused-vars": 2,
-    "no-with": 2,
-    "no-this-before-super": 2,
-    "semi": 2,
-    "strict": 0,
-    "valid-typeof": 2,
-    "wrap-iife": [2, "inside"],
-    "no-mixed-spaces-and-tabs": 2,
-    "no-trailing-spaces": 2
-  },
-  "parser": "babel-eslint"
+  "extends": "eslint-config-discourse"
 }
diff --git a/.template-lintrc.js b/.template-lintrc.js
new file mode 100644
index 0000000..dd2e0b9
--- /dev/null
+++ b/.template-lintrc.js
@@ -0,0 +1,4 @@
+module.exports = {
+  plugins: ["ember-template-lint-plugin-discourse"],
+  extends: "discourse:recommended"
+};
diff --git a/assets/javascripts/discourse-assign/assigned-group-route-map.js.es6 b/assets/javascripts/discourse-assign/assigned-group-route-map.js.es6
index 891d62c..6714f88 100644
--- a/assets/javascripts/discourse-assign/assigned-group-route-map.js.es6
+++ b/assets/javascripts/discourse-assign/assigned-group-route-map.js.es6
@@ -1,8 +1,8 @@
 export default {
   resource: "group",
   map() {
-    this.route("assigned", function() {
+    this.route("assigned", function () {
       this.route("show", { path: "/:filter" });
     });
-  }
+  },
 };
diff --git a/assets/javascripts/discourse-assign/assigned-messages-route-map.js.es6 b/assets/javascripts/discourse-assign/assigned-messages-route-map.js.es6
index afee7fd..be90c7c 100644
--- a/assets/javascripts/discourse-assign/assigned-messages-route-map.js.es6
+++ b/assets/javascripts/discourse-assign/assigned-messages-route-map.js.es6
@@ -2,5 +2,5 @@ export default {
   resource: "user.userPrivateMessages",
   map() {
     this.route("assigned");
-  }
+  },
 };
diff --git a/assets/javascripts/discourse-assign/assigns-activity-route-map.js.es6 b/assets/javascripts/discourse-assign/assigns-activity-route-map.js.es6
index 3547610..c20d643 100644
--- a/assets/javascripts/discourse-assign/assigns-activity-route-map.js.es6
+++ b/assets/javascripts/discourse-assign/assigns-activity-route-map.js.es6
@@ -2,5 +2,5 @@ export default {
   resource: "user.userActivity",
   map() {
     this.route("assigned");
-  }
+  },
 };
diff --git a/assets/javascripts/discourse-assign/connectors/above-review-filters/assigned-to-filter.hbs b/assets/javascripts/discourse-assign/connectors/above-review-filters/assigned-to-filter.hbs
index f0d83f4..a7fa229 100644
--- a/assets/javascripts/discourse-assign/connectors/above-review-filters/assigned-to-filter.hbs
+++ b/assets/javascripts/discourse-assign/connectors/above-review-filters/assigned-to-filter.hbs
@@ -1,5 +1,5 @@
- <div class='reviewable-filter discourse-assign-assign-to-filter'>
-  <label class='filter-label'>{{i18n "discourse_assign.assigned_to"}}</label>
+<div class="reviewable-filter discourse-assign-assign-to-filter">
+  <label class="filter-label">{{i18n "discourse_assign.assigned_to"}}</label>
   {{user-selector
     single=true
     fullWidthWrap=true
@@ -13,4 +13,4 @@
     placeholderKey=placeholderKey
     autocomplete="off"
   }}
- </div>
\ No newline at end of file
+</div>
diff --git a/assets/javascripts/discourse-assign/connectors/above-review-filters/assigned-to-filter.js.es6 b/assets/javascripts/discourse-assign/connectors/above-review-filters/assigned-to-filter.js.es6
index f8158a2..dd6b88b 100644
--- a/assets/javascripts/discourse-assign/connectors/above-review-filters/assigned-to-filter.js.es6
+++ b/assets/javascripts/discourse-assign/connectors/above-review-filters/assigned-to-filter.js.es6
@@ -8,8 +8,8 @@ export default {
       .split("|")
       .filter(Boolean);
     const groupNames = this.site.groups
-      .filter(group => groupIDs.includes(group.id.toString()))
+      .filter((group) => groupIDs.includes(group.id.toString()))
       .mapBy("name");
     component.set("allowedGroups", groupNames);
-  }
+  },
 };
diff --git a/assets/javascripts/discourse-assign/connectors/category-custom-settings/assign-settings.hbs b/assets/javascripts/discourse-assign/connectors/category-custom-settings/assign-settings.hbs
index 0ee2383..db707a7 100644
--- a/assets/javascripts/discourse-assign/connectors/category-custom-settings/assign-settings.hbs
+++ b/assets/javascripts/discourse-assign/connectors/category-custom-settings/assign-settings.hbs
@@ -1,5 +1,5 @@
-<h3>{{i18n 'discourse_assign.assign.title'}}</h3>
-<section class='field'>
+<h3>{{i18n "discourse_assign.assign.title"}}</h3>
+<section class="field">
   <div class="enable-accepted-answer">
     <label class="checkbox-label">
       {{input
@@ -7,7 +7,7 @@
         checked=(readonly category.enable_unassigned_filter)
         change=(action "onChangeSetting" value="target.checked")
       }}
-      {{i18n 'discourse_assign.add_unassigned_filter'}}
+      {{i18n "discourse_assign.add_unassigned_filter"}}
     </label>
   </div>
 </section>
diff --git a/assets/javascripts/discourse-assign/connectors/category-custom-settings/assign-settings.js.es6 b/assets/javascripts/discourse-assign/connectors/category-custom-settings/assign-settings.js.es6
index dcd2b94..c85e99e 100644
--- a/assets/javascripts/discourse-assign/connectors/category-custom-settings/assign-settings.js.es6
+++ b/assets/javascripts/discourse-assign/connectors/category-custom-settings/assign-settings.js.es6
@@ -5,6 +5,6 @@ export default {
         "category.custom_fields.enable_unassigned_filter",
         value ? "true" : "false"
       );
-    }
-  }
+    },
+  },
 };
diff --git a/assets/javascripts/discourse-assign/connectors/group-reports-nav-item/assigned-topic-list.js.es6 b/assets/javascripts/discourse-assign/connectors/group-reports-nav-item/assigned-topic-list.js.es6
index ace6464..0cedcb5 100644
--- a/assets/javascripts/discourse-assign/connectors/group-reports-nav-item/assigned-topic-list.js.es6
+++ b/assets/javascripts/discourse-assign/connectors/group-reports-nav-item/assigned-topic-list.js.es6
@@ -6,5 +6,5 @@ export default {
       args.group.can_show_assigned_tab &&
       args.group.assignment_count > 0
     );
-  }
+  },
 };
diff --git a/assets/javascripts/discourse-assign/connectors/user-activity-bottom/assigned-list.hbs b/assets/javascripts/discourse-assign/connectors/user-activity-bottom/assigned-list.hbs

[... diff too long, it was truncated ...]

GitHub sha: 598c7170

This commit appears in #109 which was merged by jjaffeux.