• 카테고리

    질문 & 답변
  • 세부 분야

    프론트엔드

  • 해결 여부

    미해결

observable말고 useLocalObservable안에 있는 함수도 자동으로 action적용이 될까요?

21.02.16 10:08 작성 조회수 199

0

안녕하세요. 제로초님!

항상 좋은 강의 열심히 듣고 있습니다!

혹시 observable안에 있는 함수가 자동으로 action 적용이 된다고 말씀주셨는데요! 그럼 useLocalObservable도 안에 있는함수도 자동으로 action이 적용 되는건가요?

답변 2

·

답변을 작성해보세요.

1

네 됩니다.

When using useLocalObservable, all properties of the returned object will be made observable automatically, getters will be turned into computed properties, and methods will be bound to the store and apply mobx transactions automatically. If new class instances are returned from the initializer, they will be kept as is.

0

이룸님의 프로필

이룸

질문자

2021.02.16

답변 감사드립니다!