Security News
Node.js EOL Versions CVE Dubbed the "Worst CVE of the Year" by Security Experts
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
ionic2-extend-alert
Advanced tools
Ionic2 extended version of alert component
npm install ionic2-extend-alert --save
Import module
import { NgModule, ErrorHandler } from '@angular/core';
import { IonicApp, IonicModule, IonicErrorHandler } from 'ionic-angular';
import { MyApp } from './app.component';
...
import { ExtendAlertModule } from 'ionic2-extend-alert'
@NgModule({
declarations: [
MyApp,
...
],
imports: [
ExtendAlertModule,
IonicModule.forRoot(MyApp)
],
bootstrap: [IonicApp],
entryComponents: [
MyApp,
...
],
providers: [{provide: ErrorHandler, useClass: IonicErrorHandler}]
})
export class AppModule {}
Your component
import { Component } from '@angular/core';
import {NavController, NavParams} from 'ionic-angular';
...
import { AlertController } from 'ionic2-extend-alert/dist/alert';
@Component({
selector: 'page-home',
templateUrl: 'home.html'
})
export class HomePage {
constructor(
...
public alertCtrl: AlertController
) {
}
presentConfirm() {
let alert = this.alertCtrl.create({
title: 'Hi!',
message: 'Hello Ionic2',
buttons: [
{
text: 'cancel',
role: 'cancel',
handler: () => {
console.log('Cancel clicked');
}
},
{
text: 'ok',
time:6000, // set auto-cancel time
handler: () => {
console.log('Buy clicked');
}
}
]
});
alert.present();
}
}
Button options
Property | Type | Description |
---|---|---|
time | number | auto-cancel time |
Cordova CLI: 6.4.0
Ionic Framework Version: 2.0.0
Ionic CLI Version: 2.1.18
Ionic App Lib Version: 2.1.9
Ionic App Scripts Version: 1.0.0
ios-deploy version: Not installed
ios-sim version: Not installed
OS: macOS Sierra
Node Version: v6.9.2
Xcode version: Xcode 8.2.1 Build version 8C1002
FAQs
ionic2 alert Auto-cloes
The npm package ionic2-extend-alert receives a total of 2 weekly downloads. As such, ionic2-extend-alert popularity was classified as not popular.
We found that ionic2-extend-alert demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.