ionic2可以用angular2的语法自定义组件吗
1个回答
展开全部
试试下面这个方法:
import { Component } from '@angular/core';
import { NavController } from 'ionic-angular';
import { Http } from '@angular/http';
@Component({
templateUrl: 'build/pages/home/home.html',
selector: 'my-app',
template: `<h2>1111</h2>`
})
export class HomePage {
constructor(public navCtrl: NavController) {
}
// title="okoko";
// name="lettt";
}
import { Component } from '@angular/core';
import { NavController } from 'ionic-angular';
import { Http } from '@angular/http';
@Component({
templateUrl: 'build/pages/home/home.html',
selector: 'my-app',
template: `<h2>1111</h2>`
})
export class HomePage {
constructor(public navCtrl: NavController) {
}
// title="okoko";
// name="lettt";
}
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询