ng2pairs v3.0.0
Ng2pairs
This project was generated using Angular CLI version 19.2.0.
Usage
To use this module in your @angular application simply import the module
import { PairsModule } from 'ng2pairs';
@NgModule({
declarations: [],
imports: [PairsModule.forRoot()],
})
export class ExampleModule {}If you want to use custom pictures then utilize PairsService as follows:
import { Component, OnInit } from '@angular/core';
import { PairsService } from 'ng2pairs';
@Component({
...
})
export class MyComponent implements OnInit {
constructor(private pairsService: PairsService) {
}
ngOnInit() {
this.pairsService.setImages(['path-to-image1/image1.png', 'path-to-image2/image2.png']);
}
}Above can be applied for custom cssClasses for pairs, just callthis.pairsService.setCssClasses('classRed', 'classBlue')`
Code scaffolding
Angular CLI includes powerful code scaffolding tools. To generate a new component, run:
ng generate component component-nameFor a complete list of available schematics (such as components, directives, or pipes), run:
ng generate --helpBuilding
To build the library, run:
ng build ng2pairsThis command will compile your project, and the build artifacts will be placed in the dist/ directory.
Publishing the Library
Once the project is built, you can publish your library by following these steps:
Navigate to the
distdirectory:cd dist/ng2pairsRun the
npm publishcommand to publish your library to the npm registry:npm publish
Additional Resources
For more information on using the Angular CLI, including detailed command references, visit the Angular CLI Overview and Command Reference page.
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
3 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
9 years ago
9 years ago
9 years ago
9 years ago