我正在使用离子框架来构建移动应用。 然而,在浏览器结果和构建结果中的模拟与后续图像不同。
我该如何解决这个问题?
http://i.stack.imgur.com/AYzQ3.png
http://i.stack.imgur.com/Bt2Cq.png
HTML
<ion-view view-title="More">
<ion-content class="has-header">
<ion-list>
<!-- Account details -->
<ion-item class="item-divider item-icon-left">
<i class="icon ion-person-stalker"></i>
Account management
</ion-item>
<!-- Show when user is already signed in -->
<ion-item ng-if="signedIn" class="item-icon-right" href="#/tab/yellow">
Change details
<i class="icon ion-chevron-right icon-accessory"></i>
</ion-item>
<ion-item ng-if="signedIn" class="item-icon-right" href="#/tab/yellow">
My listings
<i class="icon ion-chevron-right icon-accessory"></i>
</ion-item>
<ion-item ng-if="signedIn" class="item-icon-right" ng-click="signout()">
Sign out
<i class="icon ion-chevron-right icon-accessory"></i>
</ion-item>
<!-- Show when user isnt signed in -->
<ion-item ng-if="!signedIn" class="item-icon-right" href="#/tab/account/signin">
Sign in
<i class="icon ion-chevron-right icon-accessory"></i>
</ion-item>
<ion-item ng-if="!signedIn" class="item-icon-right" href="#/tab/account/signup">
Sign up
<i class="icon ion-chevron-right icon-accessory"></i>
</ion-item>
<!-- Useful tools -->
<ion-item class="item-divider item-icon-left">
<i class="icon ion-cash"></i>
Useful tools
</ion-item>
</ion-list>
</ion-content>
</ion-view>
控制器
angular.module('tekoria.controllers.account',[])
.controller('AccountCtrl', function($scope, $window, AccountService) {
$scope.signedIn = AccountService.current();
});
服务
angular.module('tekoria.services.account', [])
.factory('AccountService', function($rootScope) {
Parse.initialize("removed", "removed");
return {
current: function() {
return Parse.User.current();
}
};
});
答案 0 :(得分:0)
It works fine after I put libraries into the local folder rather than using a CDN