Skip to content

Commit

Permalink
Custom Initial State and Forward Actions Docs update (#2731)
Browse files Browse the repository at this point in the history
* Custom Initial State and Forward Actions Docs update
* Update Kepler GL component import

Signed-off-by: Indranil Halder <indranilhalder.dev@gmail.com>
  • Loading branch information
indranildeveloper authored Nov 4, 2024
1 parent e88577d commit 966ee4c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion docs/api-reference/advanced-usages/custom-initial-state.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Here is an example modify `uiState` `initialState` to hide side panel, and selec

```js
import {combineReducers} from 'redux';
import keplerGlReducer from 'kepler.gl/reducers';
import {keplerGlReducer} from '@kepler.gl/reducers';

const customizedKeplerGlReducer = keplerGlReducer
.initialState({
Expand Down
8 changes: 4 additions & 4 deletions docs/api-reference/advanced-usages/forward-actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ You can add a dispatch function to your component that dispatches actions to a s

```js
// component
import KeplerGl from 'kepler.gl';
import {KeplerGl} from '@kepler.gl/components';
import {connect} from 'react-redux';

// import action and forward dispatcher
import {toggleFullScreen, forwardTo} from 'kepler.gl/actions';
import {toggleFullScreen, forwardTo} from '@kepler.gl/actions';


const MapContainer = props => (
Expand Down Expand Up @@ -44,10 +44,10 @@ You can also simply wrap an action into a forward action with the `wrapTo` helpe

```js
// component
import KeplerGl from 'kepler.gl';
import {KeplerGl} from '@kepler.gl/components';

// action and wrapper
import {toggleFullScreen, wrapTo} from 'kepler.gl/actions';
import {toggleFullScreen, wrapTo} from '@kepler.gl/actions';

// create a function to wrapper action payload to 'foo'
const wrapToMap = wrapTo('foo');
Expand Down

0 comments on commit 966ee4c

Please sign in to comment.