Alexander Buzin 4c0f831c0d Change StateModule example
Former-commit-id: 3f49442d994dc9d4bcc2c41aa93f4091ca55db88
2017-06-24 18:32:41 +03:00

24 lines
645 B
Plaintext

extends ../../layout.pug
block body
div(class="note")
h4 Guide to StateModule
p
| 1) Go to the `console` in devtools.
br
| 2) Type:
br
code state.to('green');
br
| The example `plane` and `sphere` should change their color to green by loading to configuration called `green`.
br
| 3) Type:
br
code state.to('default');
br
| Now you switched back to `default` configuration.
br
| 4) You can also change only specific parameter of state using .set() :
br
code state.set({sphereColor: 0x00ff00});