Clarification on m.mount() signature
This commit is contained in:
parent
6e139e42b7
commit
592f31ee3d
1 changed files with 1 additions and 1 deletions
|
|
@ -62,7 +62,7 @@ where:
|
|||
|
||||
- **Component component**
|
||||
|
||||
A component is supposed to be an Object with two keys: `controller` and `view`. Each of those should point to a Javascript function
|
||||
A component is supposed to be an Object with two keys: `controller` and `view`. Each of those should point to a Javascript function. If the `controller` is omitted, Mithril will provide one, pointing to an empty function.
|
||||
|
||||
When `m.mount` is called, the controller function runs, and its return value is returned by the `m.mount` call.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue