jjmhalew / ngx-lightbox

Lightbox2 with Angular >= 18 (zoneless)
MIT License
0 stars 0 forks source link

Get rid of RendererRef #10

Closed jjmhalew closed 1 month ago

jjmhalew commented 1 month ago

Use the ElementRef directly instead, also as it is more type safe

Example:

this._rendererRef.setStyle(this._outerContainerElem()!.nativeElement, "height",${newHeight}px); becomes this._outerContainerElem()!.nativeElement.style.height =${newHeight}px;

jjmhalew commented 1 month ago

https://stackoverflow.com/a/39785176/16659122