Skip to content

Instantly share code, notes, and snippets.

@alexzuza
Created January 29, 2019 07:43
Show Gist options
  • Save alexzuza/fb5ca6bdd63aacae397108f47dbb6615 to your computer and use it in GitHub Desktop.
Save alexzuza/fb5ca6bdd63aacae397108f47dbb6615 to your computer and use it in GitHub Desktop.
di nodeinjector
export class NodeInjector implements Injector {
constructor(
private _tNode: TElementNode|TContainerNode|TElementContainerNode|null,
private _lView: LView) {}
get(token: any, notFoundValue?: any): any {
return getOrCreateInjectable(this._tNode, this._lView, token, undefined, notFoundValue);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment