Ionic 2找不到部署

时间:2017-04-19 15:46:15

标签: cordova angular ionic-framework ionic2

我只是关注离子文档在应用上设置Ionic Deploy但我仍然收到此错误:无法找到名称'部署' 。 随后的说明:http://docs.ionic.io/services/deploy/ 我在主要组件(app.component.ts)中的代码:

import { Component, ViewChild } from '@angular/core';
import { Deploy } from '@ionic/cloud-angular';
import { Nav, Platform } from 'ionic-angular';
import { StatusBar } from '@ionic-native/status-bar';
import { SplashScreen } from '@ionic-native/splash-screen';


import { HomePage } from '../pages/home/home';
import { EventPage } from '../pages/event/event';
import { LoginPage } from '../pages/login/login';
import { ProfilePage } from '../pages/profile/profile';

import { AuthService } from '../services/auth.service';
import { UpcomingEventsPage } from "../pages/upcoming-events/upcoming-events";
import { CoursesService } from "../services/courses.service.";

@Component({
  templateUrl: 'app.html'
})
export class MyApp {
  @ViewChild(Nav) nav: Nav;

  availableUpdate: boolean = false;

  rootPage: any = HomePage;
  loading: boolean = false;

  pages: Array<{ title: string, component: any, params: any }>;

  constructor(
        public platform: Platform, 
        public statusBar: StatusBar, 
        public splashScreen: SplashScreen,
        public coursesService: CoursesService,
        private authService: AuthService
        ,public deploy: Deploy
        ) {
    this.initializeApp();

1 个答案:

答案 0 :(得分:1)

只需要安装先决条件:angular-cloud。