Merge pull request #64 from greena13/reference_ref
[js][database] Add ref property for consistency with web API
This commit is contained in:
commit
898217ff6c
|
@ -350,6 +350,14 @@ export default class Reference extends ReferenceBase {
|
|||
return new Reference(this.database, this.path.substring(0, this.path.lastIndexOf('/')));
|
||||
}
|
||||
|
||||
/**
|
||||
* A reference to itself
|
||||
* @type {!Reference}
|
||||
* {@link https://firebase.google.com/docs/reference/js/firebase.database.Reference#ref}
|
||||
*/
|
||||
get ref(): Reference {
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a ref to the root of db - '/'
|
||||
|
|
Loading…
Reference in New Issue