When to use .toJS() with Immutable.js and Flux?

后端 未结 5 623
礼貌的吻别
礼貌的吻别 2021-01-30 16:38

I\'m trying to use ImmutableJS with my React / Flux application.

My stores are Immutable.Map objects.

I\'m wondering at which point should I use

5条回答
  •  说谎
    说谎 (楼主)
    2021-01-30 17:22

    -- No longer recommend --
    When using Redux I tend to let my connects' mapStateToProps function transform immutable structures using toJS() and allow my react components to consume the props as javascript objects.

提交回复
热议问题