Skip to content
Permalink
Browse files

v7.0.0-beta.22

  • Loading branch information
tannerlinsley committed Dec 2, 2019
1 parent 49674a0 commit 83f889dad59c3d48ca63ba06dabd1db39091f863
Showing with 19 additions and 15 deletions.
  1. +7 −7 .size-snapshot.json
  2. +4 −0 CHANGELOG.md
  3. +1 −1 README.md
  4. +1 −1 package.json
  5. +6 −6 src/plugin-hooks/useRowState.js
@@ -1,20 +1,20 @@
{
"dist/index.js": {
"bundled": 96409,
"minified": 46532,
"gzipped": 12274
"bundled": 96393,
"minified": 46534,
"gzipped": 12272
},
"dist/index.es.js": {
"bundled": 95844,
"minified": 46040,
"gzipped": 12164,
"bundled": 95828,
"minified": 46042,
"gzipped": 12160,
"treeshaked": {
"rollup": {
"code": 78,
"import_statements": 21
},
"webpack": {
"code": 11105
"code": 11109
}
}
}
@@ -1,3 +1,7 @@
## 7.0.0-beta.22

- Fixed an issue where `useRowState` would crash due to invalid initial state attempting to spread into the new state

## 7.0.0-beta.21

- Removed deprecated `defaultState` export
@@ -198,7 +198,7 @@ This library is being built and maintained by me, @tannerlinsley and I am always
#### I'm still using v6, what should I do?
v6 is a great library and is still the default install for `react-table`, however, I do not intend on offering any long-term support for it. If you intend to keep using v6, I recommend maintaining your own fork of the library and keeping it up to date for your version of React.
v6 is a great library and while it is still available for use, I do not intend on offering any long-term support for it. If you intend to keep using v6, I recommend maintaining your own fork of the library and keeping it up to date for your version of React.
#### Where are the docs for the older v6 version?
@@ -1,6 +1,6 @@
{
"name": "react-table",
"version": "7.0.0-beta.21",
"version": "7.0.0-beta.22",
"description": "A fast, lightweight, opinionated table and datagrid built on React",
"license": "MIT",
"homepage": "https://github.com/tannerlinsley/react-table#readme",
@@ -36,7 +36,7 @@ reducerHandlers[pluginName] = (state, action) => {
...state,
rowState: {
...state.rowState,
[pathKey]: functionalUpdate(value, state.rowState[pathKey]),
[pathKey]: functionalUpdate(value, state.rowState[pathKey] || {}),
},
}
}
@@ -71,18 +71,18 @@ function useMain(instance) {
)

const setCellState = React.useCallback(
(rowPath, columnId, updater) => {
(rowPath, columnId, value) => {
return setRowState(
rowPath,
old => {
return {
...old,
cellState: {
...old.cellState,
[columnId]:
typeof updater === 'function'
? updater(old.cellState[columnId])
: updater,
[columnId]: functionalUpdate(
value,
old.cellState[columnId] || {}
),
},
}
},

0 comments on commit 83f889d

Please sign in to comment.
You can’t perform that action at this time.