Releases: styleguidist/react-styleguidist
3.0.2
3.0.1
3.0.0
Breaking changes
Improved state
Previously setState
in examples was causing component rerender which was braking animation and other things.
Default state definition was changed. Instead of:
'count' in state || setState({ count : 1})
You should do:
initialState = { count: 1 };
(#51, #134 by @saschatimme)
Collapsible code examples
Now code examples are collapsed by default, you can change it by showCode option.
New features
Basic isolated links implementation
Now you can open any component in a separate page:
The UI requires more work, any help is appreciated.
Other changes and fixes
2.3.1
v2.3.0
v2.2.2
2.2.1
2.2.0
New features
Sections
Allows you to group components into sections and add random Markdown files to your style guide:
module.exports = {
// ...
sections: [
{name: 'Introduction', content: 'docs/introduction.md'},
{name: 'UI Components', content: 'docs/ui.md', components: 'lib/components/ui/*.js'}
]
}
PRs: #108 by @paulj, #119, #120 by @karlbright.
Experimental isolated mode
Try to open your styleguide like http://localhost:3000/#!/Button and only one component will be rendered (#123 by @karlbright).
Example doclets support
Now you can add additional examples to your components from external files:
/**
* Component is described here.
* @example ./extra.examples.md
*/
export default class SomeComponent extends React.Component {
// ...
}
Ability to change react-docgen behavior
New options: resolver, handler, propsParser.
PRs: #106 by @paulj, #118 by @vslinko.
Other changes and fixes
- Should work fine in React 15.0.
- Filter in the sidebar uses fuzzy search.
- Mark required props insted of optional in a props table (#102 by @CompuIves)
- Fixed: union elements share same key (#111, #112).
- Fixed CSS hook for Li tag (#101).
2.1.0
New features
Other changes and fixes
- Improved default style (#92 by @karlbright).
- Ensure components list is scrollable (#92 by @karlbright).
- Ensure missing proptypes do not throw errors (#91 by @karlbright).