Created
October 13, 2017 11:03
-
-
Save shpyo/b6641846a6607d2ed207fc417ee0989a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class SomeClass { | |
@observable prop1; | |
@observable prop2; | |
@action init(prop1, prop2) { | |
this.setProp1(prop1); // or this.prop1 = prop1; ? | |
this.setProp2(prop2); // or this.prop2 = prop2; ? | |
} | |
@action | |
setProp1(value) { | |
this.prop1 = value; | |
} | |
@action | |
setProp2(value) { | |
this.prop2 = value; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment