* [react] Use HTMLDialogElement for the dialog node
* Actually add the `open` property
* This update requires typescript 2.6
* Update dependents of react to also require typescript 2.6
* [react-router] fixed lint error due to implicit any in CustomLink test
* [react-router] added possibility to specify component props in route definitions, and to specify the type of this.props.route.props when implementing such a component
Example:
/* component definition */
interface Props { foo: string }
class MyComponent extends React.Component<RouteComponentProps<void,void,Props>, State> {
/* here you can use this.props.route.props.foo */
}
/* route configuration */
<Route path="/my-path" component={MyComponent} props={{ foo: 'bar' }}>
* - fixed lint errors related to T[] instead of Array<T>
- added default type for ComponentProps in RouteComponentProps<P,R,ComponentProps>, so that it stays compatible with existing code
* [react-router] added default route props type (any) so that this new feature is fully backward compatible
* [react-router] fixed lint errors (T[] instead of Array<T> for non-generic types)
* [react-router] Fix for --strictFunctionTypes
It seems it's not possible for a SFC to conform to React.ComponentType<RouteComponentProps<any> | {}> with both strictFunctionTypes and strictNullChecks (they have to either be `Partial<RouteComponentProps<any>>` or `{}`).
The whole point of the `| {}` is to allow for components that have defaulted `Props` / don't use any `Props` anyway, so adding it as another listed type should work.
* Fix dtslint errors
* Test
* Fix react typings
* Revert "Use []-syntax for some cases."
This reverts commit 5f6e55843980b2cff9ace4174f72b4f8aa7ad278.
* Modify another render function's return type
* Use Array<T> instead in react.d.ts & Fix issues with the typescript linter & Adapt changes in react-router
* Convert Array<T> to T[]
* Add support for string and number return types.
In react-router v3.0.5, [`withRouter`][0] passes 4 props to the wrapped
component: `location`, `params`, `router`, and `routes`. These props are
different than those passed to `Route` components; these all come
directly from the Router either via `this.props` or `this.context`.
The component passed to `withRouter` are passed these props, but the
component returned from `withRouter` require only the component's own
props.
[0]: https://github.com/ReactTraining/react-router/blob/v3.0.5/modules/withRouter.js#L40
These weak type errors were not caught in TS 2.4 RC. The final TS 2.4
will catch weak type errors with primitives, so this PR fixes those
now-caught errors.
* [react-router] add RouteComponentProps.staticContext
* [react-router] revert RouteConfig test file
* [react-router] Add example for StaticRouter and staticContext
SwitchProps.children is too strict for projects using typescript 2.3.
With typescript 2.3 the children could be made mandatory, but this will
break backwards compatibility with any ts 2.2 user