我想开始使用离子框架,但遗憾的是我已经在第一步失败了.
我正在运行Ubuntu 13.04,我安装了节点v0.10.25.我已经安装了离子,在他们的文档中描述:
sudo npm install -g cordova
sudo npm install -g ionic
Run Code Online (Sandbox Code Playgroud)
安装顺利,没有错误或警告,但安装后我输入
ionic
Run Code Online (Sandbox Code Playgroud)
我收到错误:
No command 'ionic' found, did you mean:
Command 'ionice' from package 'util-linux' (main)
Command 'sonic' from package 'sonic' (universe)
ionic: command not found
Run Code Online (Sandbox Code Playgroud)
我对ubuntu很新,所以我可能没有正确配置,但我找不到.
谢谢
我正在使用iframe来使用angularjs和离子框架显示内容.在这里,我需要给窗口高度作为iframe高度,所以我用过
$scope.iframeHeight = window.innerHeight;
Run Code Online (Sandbox Code Playgroud)
但是,我只获得1/4屏幕.
这是我到目前为止尝试过的.
的index.html
<!DOCTYPE html>
<html ng-app="ionicApp">
<head>
<!-- ionic/angularjs CSS -->
<link href="css/ionic.css" rel="stylesheet">
<link href="css/ionic-custom.css" rel="stylesheet">
<!-- ionic/angularjs js bundle -->
<script type="text/javascript" src="js/ionic.bundle.js"></script>
<script>
angular.module('ionicApp', ['ionic'])
.controller('MainCtrl', function($scope) {
$scope.iframeHeight = window.innerHeight;
});
</script>
</head>
<body ng-controller="MainCtrl">
<iframe src="http://stackoverflow.com" ng-style="{height:iFrameHeight}" id="iframeid" width="100%" ></iframe>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)
我错过了什么吗?
随着代码:
<ion-navbar *navbar>
</ion-navbar>
Run Code Online (Sandbox Code Playgroud)
后退按钮已启用.但我需要自定义它(图标或标签).可能吗?在docs/api中找不到任何内容.
我想使用Ionic 2开发应用程序,但现在我正在使用带有Ionic1的angularJS1.
我觉得AngularJs 1对我来说很舒服但不是AngularJS 2,所以有没有办法使用Ionic 2和AngularJS 1?
在Android Marshmallow中,用户在应用程序运行时向应用程序授予权限,而不是在他们安装应用程序时如何在离线时检查和授予运行时的Permissons?
我刚刚升级到Ionic 3.0.1所以我可以使用LazyLoading,因为我不能使用我的自定义Pipes:
import { Pipe, PipeTransform } from '@angular/core';
@Pipe({
name: 'StripHTML'
})
export class StripHTML implements PipeTransform {
transform(value, args) {
let striped = value.replace(/(<([^>]+)>)/g, "");
if (args != null) {
if (args.split != null) {
striped = striped.split(args.split);
if (args.index != null) {
striped = striped[args.index];
}
}
}
return striped;
}
}
Run Code Online (Sandbox Code Playgroud)
并在app.module.ts我已将其添加到声明中:
@NgModule({
declarations: [
........,
StripHTML
],
...
Run Code Online (Sandbox Code Playgroud)
现在当我试图在html模板中使用它时出错:
core.es5.js:1085 ERROR Error: Uncaught (in promise): …Run Code Online (Sandbox Code Playgroud) 我的Ionic 2应用程序中有这个网格.是否有任何特定于离子的属性使按钮显示在列(行)的右侧?
<ion-grid>
<ion-row>
<ion-col>col 1</ion-col>
<ion-col>col 2</ion-col>
</ion-row>
<ion-row>
<ion-col>
<button ion-button>My button</button>
</ion-col>
</ion-row>
</ion-grid>
Run Code Online (Sandbox Code Playgroud) 感谢firebase v 3.9.0,我的社交OAuth在我的离子应用程序中运行良好.我想做一点改变.当提示登录时,它会显示"登录以继续my-real-appname-12345f.firebaseapp.com".
如何将其更改为更加用户友好的内容,例如,应用程序的实际名称.
为了澄清,我使用firebase来处理Google和Facebook的身份验证.两条消息都是一样的.
谢谢!韦恩
今天我已将 MacBook 升级到 macOS Big Sur 版本 11.0.1。现在,当我尝试为 Android 构建项目时出现了一个问题。
Execution failed for task ':CordovaLib:compileDebugJavaWithJavac'.
> Could not find tools.jar. Please check that /Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home contains a valid JDK installation.
Run Code Online (Sandbox Code Playgroud) ionic-framework ×10
ionic2 ×4
angular ×3
ionic3 ×3
angularjs ×2
cordova ×2
javascript ×2
typescript ×2
android ×1
firebase ×1
html ×1
iframe ×1
node.js ×1
oauth-2.0 ×1
ubuntu ×1