New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Release/absolute anaconda #149
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…/function-modifiers
Merge master to anaconda release
Replacement reducer (a.k.a. modifier functions in actions)
Feature/draggable
…arcels into feature/more-more-docs
Add one bajillion docs
…arcels into release/absolute-anaconda
…rcels even when debounce or hold arent being used
…cels into feature/modify-examples
…t keypathmodifier
ParcelBoundary state synchronisation + cancelling actions
allanhortle
approved these changes
Feb 4, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
dataparcels
Contains #105, #117, #147, #150, #152, #154, #158, #159, #161, #162, #163, #164
Main points:
import {Foo} from 'bar';
) to slash exports (import Foo from 'bar/Foo';
) to allow people to have smaller bundle sizes when they use less features. This convention will become more important as optional features like Add: rekey #123 and Add: utils/segment #124 are added.modifyDown()
and.modifyUp()
. If shape editing / deep editing is required, then a parcel shape updater can be imported viaimport shape from 'dataparcels/shape
and used like.modifyDown(shape(parcelShape => parcelShape))
Fixes
Parcel.toObject()
now turns arrays into objects as expectedParcel.initialMeta
is set Bug: initialMeta deletes value #164debounce
orhold
aren't being used. Previously a regular ParcelBoundary was fully locked to props, but some freedom to have the ParcelBoundary's state move forward is safe and also necessary for the intended pattern of usingmodifyUp
to cancel invalid values.Exports
import {Action} from 'dataparcels';
becomesimport Action from 'dataparcels/Action';
ActionCreators
is no longer exported fromdataparcels
type ParcelMetaUpdater
from named exports Remove: Parcel.updateMeta #154{ParcelCreateConfigType}
{ParcelShapeSetMeta}
{ParcelShapeValueUpdater}
{ParcelShapeUpdater}
{ParcelShapeConfigInternal}
{ParentType}
Parcel methods
Parcel config.debugRender
Remove: ParcelBoundary and ParcelBoundaryHoc debugRender #159Parcel.updateMeta()
Remove: Parcel.updateMeta #154Parcel.matchPipe()
Remove: matchPipe() or replace it with branchPipe() and split out matcher #152Parcel.batch()
. UseParcel.update()
with shape updaters insteadParcel.modifyChange()
. UseParcel.modifyUp()
with shape updaters insteadParcel.batchAndReturn()
.Parcel.hasDispatched()
. Nothing should ever rely on this information, no Parcel should ever ask questions of their children.Parcel.setChangeRequestMeta()
. Seldom used feature that doesn't fit now thatParcel.batch()
is gone.ParcelBoundaryHoc
Parcel.ping()
Remove: ping and synchronous actions #161Parcel.children()
- returns the value's children as Parcels, in the current parent data container.Parcel.move()
Add: IndexedParcel.move() and https://github.com/clauderic/react-sortable-hoc example #117Parcel.push()
,Parcel.unshift()
,ParcelShape.push()
andParcelShape.unshift()
to accept multiple arguments Add: ability for push() and unshift() to take n arguments #163Parcel modify functions
Parcel.modifyValue
is now calledParcel.modifyDown
Add: Finalise and complete the modify methods #147Parcel.modifyChangeValue
is now calledParcel.modifyUp
Add: Finalise and complete the modify methods #147Parcel.modifyChangeBatch
has been removed Add: Finalise and complete the modify methods #147Parcel.update()
,Parcel.modifyDown()
andParcel.modifyUp()
to accept parcel shape updaters.import shape from 'dataparcels/shape
;.modifyDown(shape(parcelShape => parcelShape))
Parcel.modifyUp()
to return aCancelActionMarker
to cancel an action.import CancelActionMarker from 'dataparcels/CancelActionMarker
;.modifyUp(value => value !== "good" ? CancelActionMarker : value)
Actions, ChangeRequests and keyPathModifiers
Action.shouldBeSynchronous()
Remove: ping and synchronous actions #161ChangeRequest.shouldBeSynchronous()
Remove: ping and synchronous actions #161Action.toJS()
now includeskeyPathModifiers
Add: Allow for functions as actions #105ActionKeyPathModifier
s to store modifier functions directly on each action. This means that actions and change requests become truly re-runnable with different input data. A set of actions can be run through the reducer multiple times with different data and there wont be any accidental "caching" of derived data. Add: Allow for functions as actions #105Reducer
withChangeRequestReducer
which can handlekeyPathModifiers
. Add: Allow for functions as actions #105ParcelShape
ParcelShape
(previously calledStaticParcel
) Add: StaticParcel #150react-dataparcels
Exports
import {Action} from 'react-dataparcels';
becomesimport Action from 'react-dataparcels/Action';
ActionCreators
is no longer exported fromreact-dataparcels
type ParcelMetaUpdater
from named exports Remove: Parcel.updateMeta #154ParcelHoc
ParcelHoc config.debugRender
Remove: ParcelBoundary and ParcelBoundaryHoc debugRender #159{ParcelCreateConfigType}
{ParcelShapeSetMeta}
{ParcelShapeValueUpdater}
{ParcelShapeUpdater}
{ParcelShapeConfigInternal}
{ParentType}
ParcelBoundary
Parcelboundary.keepState
.react-dataparcels-drag
react-dataparcels-drag
, a plugin forreact-dataparcels
that adds drag and drop re-ordering of elements, using the wonderful react-sortable-hoc.Repo