Actually check types (#1918)

* types: stronger typings

* Remove remaining `declare module` things for uppy.use

* Format types standard-style-like

* Add `target` properties to plugin typings

* Add type for `replaceTargetContent` option

* xhr-upload: allow lowercase method

* opt in to stricter typechecks

* use the strictly typed version in all typings tests

* endtoend: use strict types in typescript test

* Add some comments to the typings file so IDEs will warn about untyped use()

* informer: remove obsolete option from typings

* react: generate prop types based on actual options types

* react: update types

* react: fix import in typings test

* companion-client: add `pluginId` property to ProviderOptions type

Co-Authored-By: Ifedapo .A. Olarewaju <ifedapoolarewaju@gmail.com>

* core: remove some `any` types

* *: add locale string types

* *: generate locale typings

* core: fix LocaleStrings<> type

* dashboard: add locale string type tests

* tus: inherit options typings from tus-js-client

* transloadit: add missing options types

* ci: do the required build steps before testing typings

* Support TokenStorage in types, add `title?: string` options

* form: update typings

* types: put TokenStorage type in dependents

* Document Uppy.StrictTypes

* if we pin at least we should use the latest

* Allow document.querySelector

I think it's a eslint-plugin-compat bug that it's marking querySelector
as not available in Android Chrome 78.

Co-authored-by: Ifedapo .A. Olarewaju <ifedapoolarewaju@gmail.com>
This commit is contained in:
Renée Kooi 2020-02-12 16:22:09 +01:00 committed by GitHub
parent 68639c2bb8
commit be66c47deb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
83 changed files with 6030 additions and 5377 deletions

1
.gitignore vendored
View file

@ -16,6 +16,7 @@ examples/dev/bundle.js
test/endtoend/create-react-app/build/
test/endtoend/create-react-app/coverage/
uppy-*.tgz
generatedLocale.d.ts
website/db.json
website/*.log