From fa6e45ea4c2036a525e049a1a37c93be64a7b6a7 Mon Sep 17 00:00:00 2001 From: Steve Baker <_steve_@outlook.com> Date: Thu, 13 Nov 2014 18:30:05 +0100 Subject: [PATCH] allow calling component or element functions no arguments --- react/react-tests.ts | 2 +- react/react.d.ts | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/react/react-tests.ts b/react/react-tests.ts index f0267d907..25185867e 100644 --- a/react/react-tests.ts +++ b/react/react-tests.ts @@ -104,4 +104,4 @@ var Timer = React.createClass({displayName: 'Timer', } }); -React.render(Timer(null), mountNode); \ No newline at end of file +React.render(Timer(), mountNode); \ No newline at end of file diff --git a/react/react.d.ts b/react/react.d.ts index 40522920f..32249bd34 100644 --- a/react/react.d.ts +++ b/react/react.d.ts @@ -4,7 +4,7 @@ // Definitions: https://github.com/borisyankov/DefinitelyTyped declare module "react" { -export = React; + export = React; } declare module React { @@ -50,11 +50,11 @@ declare module React { export interface ReactComponentFactory

{ - (properties: P, ...children: any[]): ReactComponentElement

; + (properties?: P, ...children: any[]): ReactComponentElement

; } export interface ReactElementFactory

{ - (properties: P, ...children: any[]): ReactDOMElement

; + (properties?: P, ...children: any[]): ReactDOMElement

; } export interface DomElement extends ReactElementFactory {