Asked Aug 7th, 2021 4:52 p.m. 136 0 1
  • 136 0 1
+1

Config store redux thunk

Share
  • 136 0 1

Theo doc cua redux.js.org thì khi config store thì config theo syntax : const store = createStore(rootReducer, preloadedState, composedEnhancers)

Mọi người cho mình hỏi tham số preloadedState có ý nghĩa gì vậy?

Thanks you so much.

1 ANSWERS


Answered Aug 7th, 2021 5:12 p.m.
Accepted
+1

preloadedState là giá trị state mặc định khi đc khởi tạo

https://redux.js.org/api/createstore

Share
Avatar tapcode @tapcode
Aug 8th, 2021 7:28 a.m.

Tks you bạn nhiều nha.

0
| Reply
Share
Viblo
Let's register a Viblo Account to get more interesting posts.