Skip to content

Commit fd8f9bb

Browse files
committed
move note regarding using original createSlice
1 parent b13943a commit fd8f9bb

File tree

3 files changed

+1
-2
lines changed

3 files changed

+1
-2
lines changed

examples/lazy-injection/kitchen-sink/src/features/counter/counterSlice.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ const initialState: CounterSliceState = {
1414
status: "idle",
1515
}
1616

17-
// If you are not using async thunks you can use the standalone `createSlice`.
1817
export const counterSlice = createAppSlice({
1918
name: "counter",
2019
// `createSlice` will infer the state type from the `initialState` argument
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { asyncThunkCreator, buildCreateSlice } from "@reduxjs/toolkit"
22

33
// `buildCreateSlice` allows us to create a slice with async thunks.
4+
// If you are not using async thunks you can use the standalone `createSlice`.
45
export const createAppSlice = buildCreateSlice({
56
creators: { asyncThunk: asyncThunkCreator },
67
})

examples/publish-ci/react-native/src/features/counter/counterSlice.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ const initialState: CounterSliceState = {
1313
status: "idle",
1414
}
1515

16-
// If you are not using async thunks you can use the standalone `createSlice`.
1716
export const counterSlice = createAppSlice({
1817
name: "counter",
1918
// `createSlice` will infer the state type from the `initialState` argument

0 commit comments

Comments
 (0)