[REF] component: use __ for private methods

closes #202
This commit is contained in:
Géry Debongnie
2019-06-24 13:02:12 +02:00
parent 3d2e2a1873
commit 34695883c2
8 changed files with 160 additions and 152 deletions
+7
View File
@@ -123,6 +123,8 @@ find a template with the component name (or one of its ancestor).
### Methods
We explain here all the public methods of the `Component` class.
- **`mount(target)`** (async): this is the main way a component's hierarchy is added to the
DOM: the root component is mounted to a target HTMLElement. Obviously, this
is asynchronous, since each children need to be created as well. Most applications
@@ -157,6 +159,11 @@ find a template with the component name (or one of its ancestor).
called directly (except maybe on the root component), but should be done by the
framework instead.
Obviously, these methods are reserved for Owl, and should not be used by Owl
users, unless they want to override them. Also, Owl reserves all method names
starting with `__`, in order to prevent possible future conflicts with user code
whenever Owl needs to change.
### Lifecycle
A solid and robust component system needs useful hooks/methods to help