Download wp-calypso/client/state/atomic-transfer/reducer.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 490 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/state/atomic-transfer/reducer.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/wp-calypso/client/state/atomic-transfer/reducer.js
-
curl -L -o reducer.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/state/atomic-transfer/reducer.js
490 Bytes
| import { withStorageKey } from '@automattic/state-utils'; | |
| import { ATOMIC_TRANSFER_SET } from 'calypso/state/action-types'; | |
| import { keyedReducer } from 'calypso/state/utils'; | |
| export const atomicTransfer = ( state = {}, action ) => { | |
| switch ( action.type ) { | |
| case ATOMIC_TRANSFER_SET: | |
| return { ...state, ...action.transfer }; | |
| } | |
| return state; | |
| }; | |
| //export default atomicTransferReducers; | |
| export default withStorageKey( 'atomicTransfer', keyedReducer( 'siteId', atomicTransfer ) ); | |