Created
September 2, 2022 06:05
-
-
Save NetanelBasal/7b65d6eca0c30cb25e979af0f474cbc1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Directive({ | |
standalone: true, | |
selector: 'img[rawSrc]', | |
}) | |
export class NgOptimizedImage implements OnInit, OnChanges, OnDestroy { | |
private imageLoader = inject(IMAGE_LOADER); | |
private renderer = inject(Renderer2); | |
private imgElement: HTMLImageElement = inject(ElementRef).nativeElement; | |
private injector = inject(Injector); | |
... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment