Skip to content

Commit

Permalink
FixLint in addon-info
Browse files Browse the repository at this point in the history
  • Loading branch information
usulpro committed Apr 30, 2017
1 parent 62bf99a commit 96830d0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/addon-info/src/components/Node.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ function getData(element) {
text: null,
children: null,
};

if (typeof element === 'null') {
return data
return data;
}

if (typeof element == 'string') {
Expand Down
8 changes: 6 additions & 2 deletions packages/addon-info/src/components/PropTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,11 @@ export default class PropTable extends React.Component {
const typeInfo = type.propTypes[property];
const propType = PropTypesMap.get(typeInfo) || 'other';
const required = typeInfo.isRequired === undefined ? 'yes' : 'no';
const description = type.__docgenInfo && type.__docgenInfo.props && type.__docgenInfo.props[property] ? type.__docgenInfo.props[property].description : null;
const description = type.__docgenInfo &&
type.__docgenInfo.props &&
type.__docgenInfo.props[property]
? type.__docgenInfo.props[property].description
: null;
props[property] = { property, propType, required, description };
}
}
Expand Down Expand Up @@ -73,7 +77,7 @@ export default class PropTable extends React.Component {
<th>propType</th>
<th>required</th>
<th>default</th>
<th>description></th>
<th>description&gt;</th>
</tr>
</thead>
<tbody>
Expand Down

0 comments on commit 96830d0

Please sign in to comment.