mirror of
https://github.com/flynx/object.js.git
synced 2025-10-31 19:40:09 +00:00
updated docs...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
ed1dd3a2b6
commit
e92cab8659
@ -168,8 +168,11 @@ take care of both the _function constructor_ and `prototype.__call__(..)`
|
|||||||
handling.
|
handling.
|
||||||
|
|
||||||
**Notes:**
|
**Notes:**
|
||||||
- this now is an instance method, in the future this may (or may not)
|
- `.__new__(..)` is an instance method, contrary to _Python_ that served
|
||||||
move to being a class method...
|
as an inspiration for this protocol. This is done intentionally as in
|
||||||
|
JavaScript there is no distinction between an instance and a class and
|
||||||
|
defining `.__new__(..)` in the class would both add complexity as well
|
||||||
|
as restrict the use-cases for the constructor.
|
||||||
|
|
||||||
|
|
||||||
## Components
|
## Components
|
||||||
@ -202,7 +205,7 @@ mixinFlat(<root>, <object>, ...)
|
|||||||
This is like `Object.assign(..)` but copies property objects rather than
|
This is like `Object.assign(..)` but copies property objects rather than
|
||||||
property values.
|
property values.
|
||||||
|
|
||||||
Make a raw instance
|
Make a raw (un-initialized) instance
|
||||||
```
|
```
|
||||||
makeRawInstance(<context>, <constructor>, ...)
|
makeRawInstance(<context>, <constructor>, ...)
|
||||||
-> <object>
|
-> <object>
|
||||||
|
|||||||
@ -3,6 +3,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* XXX should this extend Object???
|
* XXX should this extend Object???
|
||||||
|
* ...if yes then it would also be logical to move Object.run(..) here
|
||||||
*
|
*
|
||||||
**********************************************************************/
|
**********************************************************************/
|
||||||
((typeof define)[0]=='u'?function(f){module.exports=f(require)}:define)(
|
((typeof define)[0]=='u'?function(f){module.exports=f(require)}:define)(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user