Skip to content

Commit

Permalink
5.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesplease committed Mar 23, 2018
1 parent e22b5e1 commit f608f03
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# Changelog

### v5.0.0 (2018/3/22)

**Breaking Changes**

* When a function is included in the `components` array, it will now be called
with a different signature. Previously, it was called with one argument, `results`,
an array of the currently-accumulated results.

In React Composer v5, the function will be called with an object with two properties,
`results` and `render`. `results` is the same value as before, and `render` is the
render prop that you should place on the [React element](https://reactjs.org/docs/glossary.html#elements)
that is returned by the function.

* `mapResult` and `renderPropName` have been removed. The new signature of the function
described above gives you the information that you need to map the results, or to use
a custom render prop name.

If you need help migrating from an earlier version of React Composer, we encourage you to
read the new examples in the README. They demonstrate how you can use the new
API to accomplish the things that you previously used `renderPropName` and `mapResult` for.

### v4.1.0 (2018/2/10)

**Improvements**
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-composer",
"version": "4.1.0",
"version": "5.0.0",
"description": "Compose render prop components",
"main": "lib/index.js",
"module": "es/index.js",
Expand Down Expand Up @@ -67,4 +67,4 @@
"dependencies": {
"prop-types": "^15.6.0"
}
}
}

0 comments on commit f608f03

Please sign in to comment.