Commit Graph
64714 Commits
Author SHA1 Message Date
Hossein Saniei fc4cbfd72f feat(mongodb): add better return types for insertX functions (#38522) 2019-09-30 15:04:11 -07:00
Nathan Shively-Sanders 3d9e9bbdb7 Update react-dnd-touch-backend dnd-core dependency (#38734)
* Update react-dnd-touch-backend dnd-core dependency

dnd-core dependency goes from 4.5 to 9.3.1.
9.3.1 is the first version that fixes an incorrect export that is now
detected by Typescript 3.7.

I'm not sure this is the best fix, but I don't see a way to create a new
release of dnd-core@4.x either.

* remove react-dnd-touch-backend
2019-09-30 13:13:34 -07:00
Ifiok Jr 02c840cd68 prosemirror-view: make decorations generic (#38620) 2019-09-30 13:03:57 -07:00
Nathan Shively-Sanders 3d6e86fd92 Fix incorrect import/export clashes. (#38730)
* Fix incorrect import/export clashes.

A new error in Typescript 3.7 forbids name clashes like this:

```ts
import { X } from 'y'
export interface X { }
```

Previously they were incorrectly allowed. Typescript 3.7 will have a
beta version in the next day or two. In the meantime you can try
typescript@next -- the nightly build -- to see these errors.

* Missed a file!
2019-09-30 12:33:36 -07:00
Nathan Shively-Sanders 5299d372a2 Update react-dependent tests for TS 3.7 (#38671)
* Update react-dependent tests for TS 3.7

Typescript 3.7 includes a flag that will allow people to migrate to the
currently-specified Class Fields ECMA proposal, which is currently at
Stage 3. When `--useDefineForClassFields` is turned on, Typescript
issues 3 new errors in places where the current Typescript semantics
would cause errors with the Stage 3 spec.

Two of the errors are very rare. The third is unfortunately common in
React code because its types don't allow the type of `context` to be
inferred. Instead, components redeclare `context` with an explicit type:

```ts
class ColumnSizerExample extends React.Component<any, any> {
  context: React.ContextType<typeof MyContext>
}
```

Without `--useDefineForClassFields`, this *only* redeclares the type of
`context`. With `--useDefineForClassFields`, it redeclares the type of
`context` **and** initialises it to `undefined`. This is very
surprising.

To avoid this, Typescript 3.7 introduces new syntax for exactly this
scenario:

```ts
class ColumnSizerExample extends React.Component<any, any> {
  declare context: React.ContextType<typeof MyContext>
}
```

However, Definitely Typed tests cannot use this new syntax because it
only works with Typescript 3.7, which isn't even in beta until next
week. So this PR uses two other workarounds instead:

1. Deleting the declaration when it has the same type as the base,
usually `any`. In this case it's redundant.
2. Using a dummy initialiser:

```ts
class ColumnSizerExample extends React.Component<any, any> {
  context = {} as React.ContextType<typeof MyContext>
}
```

This is unfortunate, since it serves as a bad example to anyone reading
the tests. But I couldn't find any other way that works in all
Typescript configurations. I did, however, update the JSDoc for
`Component.context` with instructions to use the new syntax in TS 3.7
and above.

* Disable selected lint rules

* Add missing semicolon
2019-09-30 09:16:15 -07:00
Shi Yan ac2c926452 [@types/webpack] Fix chunk type (#38535)
* [@types/webpack] Fix chunk type

* Update index.d.ts

* Fix children in ToJsonOutput
2019-09-28 13:37:50 +01:00
Max Boguslavsky 8d6c370de5 Rollup plugin size snapshot (#38677)
* added rollup-plugin-size-snapshot

* fixed formatting

* fixed package.json
2019-09-27 16:52:39 -07:00
Maxim Zasorin e096c3dbaf Update react-share type definitions (#38658) 2019-09-27 16:39:28 -07:00
hassangit 0e0c991d90 update Model.bulkCreate records type (#38651)
It should be like `Model.create` record type `TCreationAttributes`
2019-09-27 16:37:56 -07:00
Jacob Rask 73c11d2cfe Make the useRouteMatch path argument optional to reflect implementation (#38650) 2019-09-27 16:34:45 -07:00
Jesse Katsumata 90e67888c4 [react-native-vector-icons] fix: Icon style (#38639) 2019-09-27 16:34:08 -07:00
Claus Stilborg 6cc0a96cca Add property setup_intent to CheckoutSession obj (#38652) 2019-09-27 16:33:11 -07:00
Chiciuc Nicușor 3c86e6bcc5 Add 'extend()' method to SimpleSchemaStatic. (#38668) 2019-09-27 16:32:04 -07:00
TypeScript Bot 62c0950505 Update CODEOWNERS (#38670) 2019-09-27 15:51:06 -07:00
Nathan Shively-Sanders 0f8f845462 Update tests for Typescript 3.7 (#38672)
Typescript 3.7 includes a flag that will allow people to migrate to the
Class Fields ECMA proposal as currently specified, which is at Stage 3.
When `--useDefineForClassFields` is turned on, Typescript
issues 3 new errors in places where the current Typescript semantics
would cause errors with the Stage 3 spec.

Two of the errors are very rare. The third shows up whenever classes want
to redeclare the type of a property from a superclass, usually when the
base property's type is `any` or `unknown`.

```ts
class ColumnSizerExample extends React.Component<any, any> {
  context: React.ContextType<typeof MyContext>
}
```

Without `--useDefineForClassFields`, this *only* redeclares the type of
`context`. With `--useDefineForClassFields`, it redeclares the type of
`context` **and** initialises it to `undefined`. This is very surprising.

To avoid this, Typescript 3.7 introduces new syntax for exactly this scenario:

```ts
class ColumnSizerExample extends React.Component<any, any> {
  declare context: React.ContextType<typeof MyContext>
}
```

However, Definitely Typed tests cannot use this new syntax because it
only works with Typescript 3.7, which isn't even in beta until next
week. So this PR uses several other workarounds instead:

1. Moving a constructor initialiser to a property declaration initialiser.
2. Using a dummy initialiser:
3. Adding type annotations so the type of the base property can be correctly inferred.
4. Deleting the declaration when it has the same type as the base. In this case it's redundant.
2019-09-27 13:01:36 -07:00
Ward Delabastita 9ae12bafb1 Update type definitions for "react-copy-to-clipboard" (#38565)
* add required property children to Props

* name function arguments for onCopy

* put required props before optional

* make all Options attributes optional and add format

* extend and add tests

* indicate lib version for these types and add contributor
2019-09-27 09:27:31 -07:00
Andrey Los a618db32ef [react-calendar-timeline] Updated types to version 0.24.6 (#38446)
* [react-calendar-timeline] Updated types to version 0.24.6
- Added absent types
- More test cases
- removed old non existent now props

* - few changes after review

* - few changes after review

* - test fix

* - fixes to header

* - fixes to labelFormat typings

* - fixes to labelFormat typings

* - fixes to typings
2019-09-27 09:26:20 -07:00
Vincenzo Chianese a3dba724ab [@types/lodash] returned object from defaults cannot be null/undefiend (#38156)
* returned object from defaults cannot be null/undefiend

* Update object.d.ts

* Update object.d.ts

* not required on any

* Update object.d.ts

* regenerate fp version
2019-09-27 09:23:57 -07:00
Dave Cardwell 07e87b67cc [puppeteer] Update definitions to 1.20.0 (#38489) 2019-09-27 09:22:37 -07:00
Maxim Mazurok f50535eb66 [gapi.client.sheets] Update Google Sheets API with fixes (#37847)
* Update Google Sheets API with fixes

Updated typings for Google Sheets, generated using https://github.com/Maxim-Mazurok/google-api-typings-generator/tree/patch-1

* Update tests for gapi.client.sheets

* Fix bugs

* Added "resource" as a Request body

https://github.com/Maxim-Mazurok/google-api-typings-generator/pull/3

* Added ClearValuesRequest interface

* Disable no-empty-interface for empty interfaces
2019-09-27 09:19:43 -07:00
Arnaud Zheng 877a5c9df4 update typings for react-native-modal-filter-picker (#38356) 2019-09-27 09:17:53 -07:00
Nathan d66a4af930 Add channelgroup type definitions to pubnub types (#38371)
* add type definitions for channelgroup methods to pubnub type definitions

* fix the code formatting after husky configs butchered it

* add tests

* check in auto-formatted code
2019-09-27 09:13:44 -07:00
a-pavlenko dc3cb890bb [serverless] extend plugin types (#38378)
* [serverless] extend plugin types

* [serverless] cover plugin types with tests

* [serverless] fix lint

* [serverless] fix identation
2019-09-27 09:12:22 -07:00
kwdowik 06484d13df Added type definitions for use-combined-reducers (#38647)
* Added type definitions for use-combined-reducers

* fixed errors

* fixed typo

* deleted typescript version declaration

* defined the same typescript version as react
2019-09-27 09:06:40 -07:00
Luís Rodrigues a6bf231f3f [typography-breakpoint-constants] new typings (#38662) 2019-09-27 08:58:12 -07:00
Luís Rodrigues 7b9dc4408e [gray-percentage] new typings (#38661) 2019-09-27 08:56:57 -07:00
Max Boguslavsky a960c0bd92 Unused files webpack plugin fix (#38660)
* fixed export

* fixed tests

* fixed formatting
2019-09-27 08:56:28 -07:00
Luís Rodrigues 13f5293ab6 adds typings for compass-vertical-rhythm (#38659) 2019-09-27 08:54:57 -07:00
Matt Bajorek 020d2e4418 Add type definitions for react-native-privacy-snapshot (#38598)
* Add type definitions for react-native-privacy-snapshot

* Fixed formatting

* Simplified code
2019-09-27 08:53:31 -07:00
Pacharapol Withayasakpunt cc2af583e5 add @types/async-eventemitter (#38203)
* add @types/async-eventemitter

* fix tests for async-eventemitter (npm test)

* fix def for listeners

* extends events/EventEmitter

* add jsdoc

* export as namespace

* formatting

* fix signature
2019-09-27 08:51:59 -07:00
Eric Mulligan 5d5d2ae0c8 Add sauronjs types (#38166)
* Started adding types.

* Missed these changes.

* Adding types.

* Should be good.

* Should be good to go.

* Updated prettier formatting.

* Updated prettier formatting.

* Updated prettier.

* Changed to ReadonlyArray.

* Modified as per review.

* Modified with other recommended changes.
2019-09-27 08:49:06 -07:00
Lydia Kats 278c2a996c [parse] Fix for const enum throwing isolatedModules error (#38472)
* fix for error enum declaration

- moved error enum declaration outside of Parse context
- changed `const enum` to `declare enum`
- added static vars for enum fields to Error class

* added test for errors
2019-09-27 08:45:27 -07:00
Jamie Magee c93e0fceac Remove re2 types (#38609)
* Remove re2 types

Available as part of the re2 package as of version 1.10.2

* Update asOfVersion re2
2019-09-27 08:42:05 -07:00
Max Boguslavsky 97c71bc7cb Added typing for xml-c14n (#38634)
* added xml-c14n typing

* reworked tests; added test run to package.json

* formatting fix

* removed package.json

* added info

* fixed errors

* rewrote typing

* reworked version

* added compile flag

* corrected export

* corrected export

* corrected tsconfig

* set noImplicitAny to false

* set other options to false

* returned back options which were turned off by mistake

* fixed typing according to review comment
2019-09-27 08:40:55 -07:00
Renan Machado 21da200696 [relay-runtime] Split files to better maintenance (#38640)
* add RelayNetworkLogger types

* add export for RelayNetworkLoggerTransaction

Fix changes suggested by TravisCI too

* add export to createRelayNetworkLogger and change type of arg

* move Network loggers to separate files

* add tests to RelayNetworkLogger

* add RelayNetworkTypes

* add RelayObservable

* add RelayNetwork

* add RelayQueryResponseCache

* add RelayRuntimeTypes

* add RelayFeatureFlags

* add RelayDeclarativeMutationConfig

* add applyOptimisticMutation

* add commitMutation

* add commitLocalUpdate

* add isRelayModernEnvironment

* add RelayRecordState

* add RelayStoreTypes

* add RelayRecordSource

* add RelayModernStore

* add RelayModernSelector

* add RelayModernOperationDescriptor

* add createFragmentSpecResolver

* add RelayStoreUtils

* add RelayModernGraphQLTag

* add fetchQuery

* add requestSubscription

* add RelayDefaultHandlerProvider

* add RelayDefaultMissingFieldHandlers

* add RelayModernEnvironment

* add RelayProfiler

* remove index imports

* remove declarations from index

* make imports and exports of index match source

* export RelayConcreteNode

* add MutationTypes and RangeOperations

* change type of graphql arg func

* change RelayDefaultHandlerProvider

* change RelayQueryResponseCache to default export

* change Environment of commitMutation

* Fix ConnectionHandler exports.
2019-09-27 14:53:35 +02:00
Romain Faust f5f1e2100b [react-native] Add resetBeforeIteration to LoopAnimationConfig (#38627)
* fix(react-native): add `resetBeforeIteration` to `LoopAnimationConfig`

* chore(react-native): update contributors list
2019-09-27 10:57:01 +02:00
dadapowell 3b1a72a2ea Add delimiterLazyShow to CleaveOptions (#38349) 2019-09-26 17:14:18 -07:00
Gavin Gregory 793e9f235f extended the OptimizedSvg interface to include path, and info width and height. (#38317) 2019-09-26 17:12:58 -07:00
Takashi Tamura f161e550b4 update workerpool to v5 (#38382)
* update workerpool to v5

* follow tslint

* update function pool doc
2019-09-26 17:03:37 -07:00
Syncfusion-JavaScript 6aad817004 17.3.0.9-beta added (#38497)
* 17.2.0.34 added

* Added non-npm package

* Removed space

* added new line
added ew line

* Changed the word

* 17.2.0.46 added

* Removed blank line and added non-npm entry

* changed Encoding format

* 17.3.0.9-beta added

* added npm packages
added npm packages

* added npm packages

* format changes

* format changed
format changed

* Format changed to ANSI
2019-09-26 16:55:58 -07:00
Mihail Parvanov a17c4bcc20 Update Kendo ui version to 2019.3.917 (#38459) 2019-09-26 16:52:58 -07:00
BRAMILLE Sébastien 498618d8d5 Update mongoose-paginate & mongoose-paginate-v2 populate types (#38303)
* Update mongoose-paginate & mongoose-paginate-v2 populate types

* Add QueryPopulateOptions

* Upgrade typescript to 2.8 as the tslint does not succeed with the 2.3
2019-09-26 16:51:45 -07:00
Oliver Joseph Ash f4cf543466 react-redux: correct connect return type (#38179) 2019-09-26 16:41:43 -07:00
Max Boguslavsky 092ed17330 Unused files webpack plugin (#38636)
* added typing

* corrected formatting

* added semicolon
2019-09-26 16:27:09 -07:00
Max Boguslavsky 13e90c82cf Type for Signalfx package (#38638)
* added signalfx

* fixed test errors

* fixed test errors
2019-09-26 16:19:50 -07:00
Tvrtko Majstorović 8d3e4aacc9 [@types/hdkey] Add declarations for toJSON and fromJSON (ver. 1.1.1) (#38517)
* Add toJSON and fromJSON to HDNode declaration

* Add credentials
2019-09-26 16:10:12 -07:00
Ivan Zverev 99078a21ed Add types for draftjs-to-html (#38588)
* Add types for draftjs-to-html

* Add types for draftjs-to-html: remove excess blank line

* Add types for draftjs-to-html: change function export
2019-09-26 16:09:04 -07:00
Robert Stocks a9c67da719 lodash: fix flattenDeep to correctly handle strings (#38625)
* lodash: fix flattenDeep to correctly handle strings

* fix whitespace
2019-09-26 16:06:08 -07:00
Matthew Peveler 50fab9758a add: type definitions for isstream (#38611)
* add: type definitions for isstream

* address reviewers comments
2019-09-26 16:03:47 -07:00
James Hong 87be2f30cd Adds type support for subset declaration (#38617) 2019-09-26 15:22:12 -07:00