otp-siddu007
v0.0.11
Published
'otp-Sidddu007' is one time password generator in angular and can be used as password generator.
Downloads
2
Readme
OtpSidddu007
'otp-Sidddu007' is one time password generator in angular and can be used as password generator.
Installation
Usage
import { Component } from '@angular/core';
import { generateOTP } from 'otp-sidddu007';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
})
export class AppComponent {
title = 'customOtp';
generateOTP() {
let def_number_otp = generateOTP();
console.log('Default Number', def_number_otp);
let number_otp = generateOTP('5754865879', 's');
console.log('number', number_otp);
let string_otp = generateOTP('asdrghytre', 's');
console.log('string', string_otp);
}
}
# app.component.html
<button (click)="generateOTP()"> Generate Otp </button>