Browse Source

silence or fix lint warnings (#2665)

Renée Kooi 4 years ago
parent
commit
f4eb113bbc

+ 4 - 1
.eslintrc.json

@@ -14,7 +14,7 @@
   "rules": {
     "jsx-quotes": ["error", "prefer-double"],
     "compat/compat": ["error"],
-    "react/jsx-handler-names": ["warn"], // maybe we want to do this in the future?
+    "react/jsx-handler-names": ["off"],
     "react/react-in-jsx-scope": ["error"],
 
     "jsdoc/check-alignment": ["warn"],
@@ -31,6 +31,9 @@
     "react": {
       "pragma": "h"
     },
+    "jsdoc": {
+      "mode": "typescript"
+    },
     "polyfills": [
       "Promise",
       "fetch",

+ 0 - 1
packages/@uppy/provider-views/src/ProviderView/ProviderView.js

@@ -146,7 +146,6 @@ module.exports = class ProviderView {
    * Fetches new folder
    *
    * @param  {object} folder
-   * @param  {string} title Folder title
    */
   getNextFolder (folder) {
     this.getFolder(folder.requestPath, folder.name)

+ 4 - 1
packages/@uppy/transloadit/src/Client.js

@@ -18,9 +18,12 @@ module.exports = class Client {
    * Create a new assembly.
    *
    * @param {object} options
+   * @param {string|object} options.params
+   * @param {object} options.fields
+   * @param {string} options.signature
+   * @param {number} options.expectedFiles
    */
   createAssembly ({
-    templateId,
     params,
     fields,
     signature,

+ 1 - 1
packages/@uppy/tus/src/index.js

@@ -256,7 +256,7 @@ module.exports = class Tus extends Plugin {
         }
       }
 
-      /** @type {{ [name: string]: string }} */
+      /** @type {Record<string, string>} */
       const meta = {}
       const metaFields = Array.isArray(opts.metaFields)
         ? opts.metaFields

+ 1 - 2
website/build-examples.js

@@ -112,8 +112,7 @@ glob(srcPattern, (err, files) => {
      * Creates bundle and writes it to static and public folders.
      * Changes to
      *
-     * @param  {[type]} ids [description]
-     * @returns {[type]}     [description]
+     * @param  {string[]} ids
      */
     function bundle (ids = []) {
       ids.forEach((id) => {