Skip to content

Commit 5203a95

Browse files
Update version string / changelog for 5.5.0 release
1 parent ee19eb2 commit 5203a95

File tree

2 files changed

+63
-1
lines changed

2 files changed

+63
-1
lines changed

CHANGELOG.md

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,65 @@
1+
## [5.5.0](https://github.com/cleandart/react-dart/compare/5.4.0...5.5.0)
2+
3+
__New Features__
4+
5+
- 🎉 🎉 🎉 __Support for function components, memo and hooks!!!__ 🎉 🎉 🎉
6+
7+
Sooooo much work from so many amazing people made this possible, but to summarize:
8+
9+
- [#221] Add support for function components
10+
- [#252] Add support for `memo` higher order component
11+
- Hooks, hooks, and more hooks!
12+
- [#223] useState
13+
- [#233] useCallback
14+
- [#237] useContext
15+
- [#227] useEffect
16+
- [#248] useLayoutEffect
17+
- [#232] useReducer
18+
- [#245] useRef
19+
- [#250] useMemo
20+
- [#247] useImperativeHandle
21+
- [#246] useDebugValue
22+
23+
<p><br>It works like this...</p>
24+
25+
Define the component:
26+
```dart
27+
import 'package:react/react.dart' as react;
28+
29+
final SomeWidget = react.registerFunctionComponent(_SomeWidget, displayName: 'SomeWidget');
30+
31+
_SomeWidget(Map props) {
32+
// You can use hooks in here, too!
33+
34+
return react.div({}, [
35+
// Some children...
36+
]);
37+
}
38+
```
39+
40+
Render the component _(exact same consumer API as a class-based component)_:
41+
```dart
42+
import 'package:react/react_dom.dart' as react_dom;
43+
import 'some_widget.dart'; // Where your component is defined
44+
45+
main() {
46+
final renderedWidget = SomeWidget({
47+
// put some props here
48+
}, [
49+
// put some children here!
50+
]);
51+
52+
react_dom.render(renderedWidget, querySelector('#idOfSomeNodeInTheDom'));
53+
}
54+
```
55+
56+
> Check out all the [function component and hooks examples](https://github.com/cleandart/react-dart/blob/c9a1211d5d77a9e354b864e99ef8f52b60eeff85/example/test/function_component_test.dart) for more information!
57+
58+
__Fixes / Updates__
59+
- [#253] Deprecate `setClientConfiguration`.
60+
- It is no longer necessary - and can be removed from your implementations
61+
- [#273] Make `JsBackedMap.values` compatible with MSIE 11
62+
163
## [5.4.0](https://github.com/cleandart/react-dart/compare/5.3.0...5.4.0)
264
365
__New Features__

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: react
2-
version: 5.4.0
2+
version: 5.5.0
33
authors:
44
- Samuel Hapák <samuel.hapak@gmail.com>
55
- Greg Littlefield <greg.littlefield@workiva.com>

0 commit comments

Comments
 (0)