当前位置: 首页>>代码示例>>TypeScript>>正文


TypeScript pro.Pro类代码示例

本文整理汇总了TypeScript中@ionic/pro.Pro的典型用法代码示例。如果您正苦于以下问题:TypeScript Pro类的具体用法?TypeScript Pro怎么用?TypeScript Pro使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了Pro类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。

示例1: constructor

import { BrowserModule } from '@angular/platform-browser';
import { ErrorHandler, NgModule, Injectable, Injector } from '@angular/core';
import { IonicApp, IonicErrorHandler, IonicModule } from 'ionic-angular';
import { SplashScreen } from '@ionic-native/splash-screen';
import { StatusBar } from '@ionic-native/status-bar';
import { Pro } from '@ionic/pro';
import { MyApp } from './app.component';
import { HomePage } from '../pages/home/home';
Pro.init('2066f7b9', {
  appVersion: '0.0.1'
})

@Injectable()
export class MyErrorHandler implements ErrorHandler {
  ionicErrorHandler: IonicErrorHandler;

  constructor(injector: Injector) {
    try {
      this.ionicErrorHandler = injector.get(IonicErrorHandler);  
       //   alert("constructor try");
    } catch(e) {
      //alert("error:"+e);
      // Unable to get the IonicErrorHandler provider, ensure
      // IonicErrorHandler has been added to the providers list below
    }
  }

  handleError(err: any): void {
    //alert("err:"+err);
    Pro.monitoring.handleNewError(err);
    // Remove this if you want to disable Ionic's auto exception handling
开发者ID:terrytang0702,项目名称:DeployApp,代码行数:31,代码来源:app.module.ts

示例2: constructor

import { BrowserModule } from '@angular/platform-browser';
import { IonicApp, IonicModule, IonicErrorHandler } from 'ionic-angular';

import { MyApp } from './app.component';

import { AboutPage } from '../pages/about/about';
import { ContactPage } from '../pages/contact/contact';
import { HomePage } from '../pages/home/home';
import { TabsPage } from '../pages/tabs/tabs';

import { StatusBar } from '@ionic-native/status-bar';
import { SplashScreen } from '@ionic-native/splash-screen';

// set my app Id
Pro.init("31e1854a", {
  appVersion: "0.0.1"
})

@Injectable()
export class MyErrorHandler implements ErrorHandler {
  ionicErrorHandler: IonicErrorHandler;

  constructor(injector: Injector) {
    try {
      this.ionicErrorHandler = injector.get(IonicErrorHandler);
    } catch(e) {
      console.error("unable to get the IonicErrorHandler provider, ensure");
      console.error("IonicErrorHandler has been added to the providers list below!");
    }
  }
开发者ID:jenart,项目名称:SweetApp,代码行数:30,代码来源:app.module.ts

示例3:

import { ErrorHandler, NgModule } from '@angular/core';
import { IonicApp, IonicErrorHandler, IonicModule } from 'ionic-angular';
import { SplashScreen } from '@ionic-native/splash-screen';
import { StatusBar } from '@ionic-native/status-bar';

import { MyApp } from './app.component';
import { HomePage } from '../pages/home/home';

import { HomeProvider } from '../providers/home/home';

import { HttpModule, JsonpModule } from '@angular/http';
import { HttpClientModule } from '@angular/common/http';


Pro.init('8bd4c1dd', {
  appVersion: '0.0.1'
});

@NgModule({
  declarations: [
    MyApp,
    HomePage,
  ],
  imports: [
    BrowserModule,
   HttpModule,
    JsonpModule,
    HttpClientModule,
    IonicModule.forRoot(MyApp)
  ],
  bootstrap: [IonicApp],
开发者ID:wahegurujee,项目名称:ionicProject,代码行数:31,代码来源:app.module.ts

示例4:

import { BrowserModule } from '@angular/platform-browser';
import { Pro } from '@ionic/pro';
import { ErrorHandler, NgModule } from '@angular/core';
import { IonicApp, IonicErrorHandler, IonicModule } from 'ionic-angular';
import { SplashScreen } from '@ionic-native/splash-screen';
import { StatusBar } from '@ionic-native/status-bar';
import { ScreenOrientation } from '@ionic-native/screen-orientation';

import { MyApp } from './app.component';
import { BookPage } from '../pages/book/book';
import { TocPage } from '../pages/toc/toc';
import { SettingsPage } from '../pages/settings/settings';

Pro.init('f9f2f3cc', {
  appVersion: '1.0'
})

@NgModule({
  declarations: [
    MyApp,
    BookPage,
    TocPage,
    SettingsPage
  ],
  imports: [
    BrowserModule,
    IonicModule.forRoot(MyApp)
  ],
  bootstrap: [IonicApp],
  entryComponents: [
    MyApp,
开发者ID:ibby89,项目名称:hajjapp,代码行数:31,代码来源:app.module.ts

示例5: handleError

import { ErrorHandler, NgModule } from '@angular/core';
import { IonicApp, IonicErrorHandler, IonicModule } from 'ionic-angular';
import { SplashScreen } from '@ionic-native/splash-screen';
import { StatusBar } from '@ionic-native/status-bar';
import { InAppBrowser } from '@ionic-native/in-app-browser';
import { MomentModule } from 'angular2-moment';

import { MyApp } from './app.component';
import { SharedModule } from './shared.module';
import { GreybackProvider } from '../providers/greyback/greyback';
import { AudioProvider } from '../providers/audio/audio';
import { HttpClientModule } from '@angular/common/http';

import { Pro } from '@ionic/pro';
const IonicPro = Pro.init('2191a4b0', {
	appVersion: "1.0.0"
});
export class MyErrorHandler implements ErrorHandler {
	handleError(err: any): void {
		IonicPro.monitoring.handleNewError(err);
	}
}
@NgModule({
	declarations: [
		MyApp
	],
	imports: [
		BrowserModule,
		HttpModule,
		IonicModule.forRoot(MyApp, {
			mode: 'ios'
开发者ID:tonymccallie,项目名称:gracepoint,代码行数:31,代码来源:app.module.ts

示例6: constructor

import { IonicApp, IonicErrorHandler, IonicModule } from 'ionic-angular';
import { SplashScreen } from '@ionic-native/splash-screen';
import { StatusBar } from '@ionic-native/status-bar';

import { MyApp } from './app.component';
import { HomePage } from '../pages/home/home';
import { ArchivedTodosPage } from '../pages/archived-todos/archived-todos';
import { TodoProvider } from '../providers/todo/todo';
import { HttpModule } from '@angular/http';
import { HttpClientModule } from '@angular/common/http';

import { Pro } from '@ionic/pro';
import { Injectable, Injector } from '@angular/core';

Pro.init('dc972ad6', {
  appVersion: '0.0.1'
})

@Injectable()
export class MyErrorHandler implements ErrorHandler {
  ionicErrorHandler: IonicErrorHandler;

  constructor(injector: Injector) {
    try {
      this.ionicErrorHandler = injector.get(IonicErrorHandler);
    } catch(e) {
      // Unable to get the IonicErrorHandler provider, ensure
      // IonicErrorHandler has been added to the providers list below
    }
  }
开发者ID:wmswina,项目名称:todo,代码行数:30,代码来源:app.module.ts


注:本文中的@ionic/pro.Pro类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。