Tag: ionic framework

在Ubuntu 16.04中安装离子时出错

我已经有cordova安装和工作,现在当我跑npm install -g ionic我得到了以下错误 npm ERR! Linux 4.4.0-64-generic npm ERR! argv "/home/daniel/.nvm/versions/node/v6.2.2/bin/node" "/home/daniel/.nvm/versions/node/v6.2.2/bin/npm" "install" "-g" "ionic" npm ERR! node v6.2.2 npm ERR! npm v3.9.5 npm ERR! path /home/daniel/.nvm/versions/node/v6.2.2/lib/node_modules/.staging/ansi-e973c662 npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall rename npm ERR! enoent ENOENT: no such file or directory, rename '/home/daniel/.nvm/versions/node/v6.2.2/lib/node_modules/.staging/ansi-e973c662' -> '/home/daniel/.nvm/versions/node/v6.2.2/lib/node_modules/ionic/node_modules/cordova-lib/node_modules/ansi' npm ERR! […]

500内部服务器错误URL:http:// localhost:8100 / api / timeline

500 URL的内部服务器错误: http:// localhost:8100 / api / timeline dev4living / HeyCommunity 我试图在本地主机上运行dev4living / HeyCommunity webApp,但出现以下错误: 错误:在TCPConnectWrap.afterConnect [ascomplete]处输出exports._exceptionWithHostPort(util.js:1045:20)时,在Object.exports._errnoException(util.js:1022:11)处连接EADDRINUSE 127.0.0.1:8100(net.js: 1087:14) HTTP://本地主机:8100 / -i使用最新的更新dev-playing:dev4living / HeyCommunity-backend和dev4living / HeyCommunity-frontendenter这里的代码 – 我该怎么办才能解决这个错误? – 您的援助将非常感激。

创build离子应用程序时出错

创build离子空白应用程序时出现此错误。 请帮我解决这个问题。 Error with start undefined Error initializing app: There was an error with the spawned command: npminstall There was an error with the spawned command: npminstall

离子运行android – 错误:找不到模块“内部/ fs” – 窗口

当我试图通过使用Windows操作系统在我的真实设备中运行Ionic应用程序 这个cmd: >离子运行android 得到这个错误: Error: Cannot find module 'internal/fs' at Function.Module._resolveFilename (module.js:470:15) at Function.Module._load (module.js:418:25) at Module.require (module.js:498:17) at require (internal/module.js:20:19) at evalmachine.<anonymous>:18:20 at Object.<anonymous> (C:\Users\MyPC\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\node_modules\vinyl-fs\node_modules\graceful-fs\fs.js:11:1) at Module._compile (module.js:571:32) at Object.Module._extensions..js (module.js:580:10) at Module.load (module.js:488:32) at tryModuleLoad (module.js:447:12) Cannot find module 'internal/fs' (CLI v1.7.16) Your system information: Cordova CLI: 6.3.1 Ionic Framework Version: 1.3.1 Ionic […]

没有任何错误显示。 代码工作正常

app.js angular.module('app', ['ionic', 'ui.router']) .config(('$urlRouterProvider', '$stateProvider', function($urlRouterProvider,$stateProvider){ $urlRouterProvider.otherwise('/'); $stateProvider .state('view',{ url:'/', templateUrl:'js/components/view/view32.html', controller:'viewCtrl' }) })) server.js var express= require('express'); var mongoose = require('mongoose'); var bodyParser=require('body-parser'); var cors= require('cors'); var app= express(); var multiparty= require('connect-multiparty'); var multipartMiddleware= multiparty(); var viewController=require('./controllers/viewController'); var shareController=require('./controllers/shareController'); var configs = require('./configs/config.js'); configs.setConfigs(); mongoose.connect(process.env.MONGO_URL); app.use(bodyParser.json()); app.use(bodyParser.urlencoded({ extended: true })); app.use(multipartMiddleware); app.use(cors()); app.use('/app', […]

用Angular http发送Ionic请求

我有一个离子应用程序,我试图发送我的Stripe令牌,付款处理。 当我用curl发送请求到node服务器时,它正在接收请求。 但是,当我尝试通过Angular的http模块发送请求时,它根本没有注册。 所有这些目前正在本地进行testing,所以这可能是问题的一部分? HTML <button (click)="testPost()" ion-button full>TEST POST</button> cart.ts … import {Http, Headers, RequestOptions} from '@angular/http'; import { Stripe } from '@ionic-native/stripe'; @Component({ selector: 'page-cart', templateUrl: 'cart.html', }) export class Cart { constructor( … private http: Http, private stripe: Stripe ) { // }); } testPost() { var headers = new Headers(); headers.append("Accept", […]

运行离子服务面对错误后:无法find“节点”的types定义文件

运行离子服务面临错误后:无法find“节点”的types定义文件。 我已经重新安装了离子,cordova和node.js,但仍然面临这个错误 C:\Users\ali\Documents\TransporterApp>ionic serve [INFO] Starting app-scripts server: –port 8100 –p 8100 –livereload-port 35729 –r 35729 –address 0.0.0.0 – Ctrl+C to cancel [21:24:00] watch started … [21:24:00] build dev started … [21:24:00] clean started … [21:24:00] clean finished in 3 ms [21:24:00] copy started … [21:24:00] transpile started … [21:24:07] typescript: …ts/TransporterApp/node_modules/@angular/tsc-wrapped/src/vinyl_file.d.ts, line: 1 Cannot […]

未处理的错误事件与离子服务

这是错误 events.js:160 throw er; // Unhandled 'error' event ^ Error: spawn C:\Program Files (x86)\nodejs\node.exe ENOENT at notFoundError (E:\IonicProjects\projectapp\ionic3\node_modules\cross-spawn\lib\enoent.js:11:11) at verifyENOENT (E:\IonicProjects\projectapp\ionic3\node_modules\cross-spawn\lib\enoent.js:46:16) at ChildProcess.cp.emit (E:\IonicProjects\projectapp\ionic3\node_modules\cross-spawn\lib\enoent.js:33:19) at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12) 我不明白为什么这个错误发生,我一直在这个项目上工作了一段时间,现在只有这个项目给了我这个错误,我已经testing了与我做的其他项目,它服务OK ,我读过关于ENOENT,但我不明白为什么我必须在我的项目上添加代码,如果我从来没有改变过库或什么的。 注意:我正在运行Windows 10

Coffescript + Ionic

我期待在CoffeeScript中使用Ionic框架构build混合移动应用程序。 该应用程序的function是login/注册; 把图片上传到mongodb中存储。 什么是这个应用程序的完整堆栈build议? https://github.com/diegonetto/generator-ionic覆盖了客户端(除了在JavaScript中,我将find一种方法使其与CoffeeScript一起工作) 在服务器端; mongoose+护照+我还需要什么? https://github.com/malikov/Authenticate.me-client-cordova-ionic https://github.com/malikov/Authenticate.me-Node-Server

Nodejs通过id获取用户

我使用MEAN堆栈的app ,我有用户,我注册和login使用satellizer一切正常。 但是,当我尝试通过它的身份证get用户我什么也没有得到,我可以做请求获取所有用户,但不是通过身份证。 请注意使用Ionicframework作为forntEnd框架。 这里是我的后端的代码: app.get('/api/me', function(req, res) { User.findById(req.user, function(err, user) { console.log(req.user); console.log(user); res.send(user); }); }) 我的前端代码控制器: .controller('ProfileCtrl', function($scope, $http, $stateParams, $ionicLoading, $timeout, $stateParams) { $ionicLoading.show({ template: 'Loading…' }); $http.get('http://localhost:3000/api/me') .success(function(data) { console.log("Recived data via HTTP", data); $timeout(function() { $ionicLoading.hide(); $scope.user = data; }, 1000); }) .error(function() { console.log("Error while getting the data"); […]