Gathering detailed insights and metrics for ngx-lazy-loading-images
Gathering detailed insights and metrics for ngx-lazy-loading-images
Gathering detailed insights and metrics for ngx-lazy-loading-images
Gathering detailed insights and metrics for ngx-lazy-loading-images
ngx-lazy-images
lazy loaded images with a small thumbnail, similar to Medium way of loading large images.
@jfkz/ngx-lazy-load-images
Image lazy load library for Angular 2+.
@doughlass/ngx-lazy-load-images
Image lazy load library for Angular 15+.
ng-responsive-carousel
Carousel for Angular. A simple solution for horizontal scrolling images with lazy loading.
An Angular library that lazy loads images with IntersectionObserver API
npm install ngx-lazy-loading-images
Typescript
Module System
Node Version
NPM Version
TypeScript (69.26%)
HTML (17.26%)
JavaScript (12.74%)
CSS (0.74%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
3 Stars
6 Commits
1 Branches
1 Contributors
Updated on Jul 29, 2019
Latest Version
0.0.1
Package Id
ngx-lazy-loading-images@0.0.1
Unpacked Size
133.50 kB
Size
26.49 kB
File Count
27
NPM Version
6.4.1
Node Version
8.12.0
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
1
2
An Angular library that lazy load images with IntersectionObserver API
1npm install --save ngx-lazy-loading-images
1import { NgModule } from '@angular/core'; 2import { NgxLazyImagesModule } from ngx-lazy-loading-images; 3 4@NgModule({ 5 imports: [ 6 ... 7 NgxLazyImagesModule 8 ], 9 ... 10}) 11export class AppModule { }
What is it? - Angular component that lazy loads images with IntersectionObserver
1 <ngx-lazy-loading-images 2 [src]="'https://via.placeholder.com/300x300'" 3 [height]="'300'" 4 [width]="'300'" 5 ></ngx-lazy-loading-images>
The options object passed into the [config]
input object is passed into the IntersectionObserver()
constructor and lets you control the circumstances under which the observer's callback is invoked. It has the following fields:
root:
rootMargin:
threshold:
Image component working similar with standard img
tag and with the following props.
Input | Type | Required | Description |
---|---|---|---|
src | string | ✓ | The image source. eg: 'https://via.placeholder.com/300x300' |
height | number | Image height (Defaults to img src height) | |
width | number | Image width (Defaults to img src width) | |
alt | string | This attribute defines an alternative text description of the image. | |
placeholder | string | Placeholder until image loads. A CSS background property, eg: #3A6073 or linear-gradient(to right, #4389A2, #5C258D) . Defaults to linear-gradient(to right, #3A6073, #16222A) . |
1 import {Component, OnInit} from '@angular/core'; 2 3 @Component({ 4 selector: 'app-root', 5 templateUrl: './app.component.html', 6 styleUrls: ['./app.component.scss'] 7 }) 8 export class AppComponent implements OnInit { 9 title = ngx-lazy-loading-images; 10 config: IntersectionObserverInit; 11 12 ngOnInit(): void { 13 const $rootElement = document.querySelector('.container'); 14 this.config = { 15 root: $rootElement, 16 rootMargin: '0px 0px 200px 0px' 17 }; 18 } 19 }
1 <ngx-lazy-loading-images 2 [src]="'https://via.placeholder.com/300x300'" 3 [alt]="'300X300'" 4 [config]="config" 5 [height]="'300'" 6 [width]="300" 7 ></ngx-lazy-loading-images>
1npm install
1ng build ng-surveys
1ng build ng-surveys --watch || npm run start:lib
1ng serve || npm run start
http://localhost:4200/
. The app will automatically reload if you change any of the source files.Run ng generate component component-name
to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module
.
Run ng build
to build the project. The build artifacts will be stored in the dist/
directory. Use the --prod
flag for a production build.
Run ng test
to execute the unit tests via Karma.
Run ng e2e
to execute the end-to-end tests via Protractor.
To get more help on the Angular CLI use ng help
or go check out the Angular CLI README.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
no SAST tool detected
Details
Reason
Found 0/6 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
157 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-07-14
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More