diff --git a/.babelrc b/.babelrc index 832059455..a96fd673e 100644 --- a/.babelrc +++ b/.babelrc @@ -1,3 +1,6 @@ { "presets": [["@babel/preset-flow", { "all": true }]] - } \ No newline at end of file + + } + + \ No newline at end of file diff --git a/package.json b/package.json index 8ffeeef92..beceb0ba9 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,8 @@ "test": "npx tsc && nyc --reporter=html --reporter=text-summary mocha", "coverage": "nyc report --reporter=text-lcov > ./coverage/lcov.info", "coveralls": "nyc report --reporter=text-lcov | coveralls && rm -r coverage", - "build": "babel src/ -d dist/" + "build": "babel src/ -d dist/", + "flow": "flow" }, "nyc": { "exclude": [ @@ -166,6 +167,7 @@ "eslint": "^8.31.0", "eslint-config-nodebb": "^0.2.1", "eslint-plugin-import": "2.26.0", + "flow-bin": "^0.219.2", "grunt": "1.5.3", "grunt-contrib-watch": "1.1.0", "husky": "8.0.2", diff --git a/src/controllers/category.js b/src/controllers/category.js index 5004cafca..4a34e2d40 100644 --- a/src/controllers/category.js +++ b/src/controllers/category.js @@ -1,3 +1,5 @@ +// @flow + 'use strict';