diff --git a/docs/docs/ref-03-component-specs.md b/docs/docs/ref-03-component-specs.md index 20efc831cc3..3183b6cf125 100644 --- a/docs/docs/ref-03-component-specs.md +++ b/docs/docs/ref-03-component-specs.md @@ -96,6 +96,16 @@ string displayName ``` The `displayName` string is used in debugging messages. JSX sets this value automatically; see [JSX in Depth](/react/docs/jsx-in-depth.html#react-composite-components). +For reading it can be accessed with `constructor.displayName`. For example: + +```javascript +var MyComponent = React.createClass({ + displayName: 'MyDisplayName', + render: function() { + return