I have (since beta4) been unable to get any of the (typescript) starters working using code such as the following (for the default Tab starter)
ionic start TEST --v2 --ts
which has package.json
:
"dependencies": {
"angular2": "2.0.0-beta.15",
"es6-shim": "^0.35.0",
"ionic-angular": "2.0.0-beta.6",
"ionic-native": "^1.1.0",
"ionicons": "3.0.0-alpha.3",
"rxjs": "5.0.0-beta.2"
},
"devDependencies": {
"del": "2.2.0",
"gulp": "3.9.1",
"gulp-watch": "4.3.5",
"ionic-gulp-browserify-typescript": "^1.1.0",
"ionic-gulp-fonts-copy": "^1.0.0",
"ionic-gulp-html-copy": "^1.0.0",
"ionic-gulp-sass-build": "^1.0.0",
"ionic-gulp-scripts-copy": "^1.0.1",
"run-sequence": "1.1.5"
},
Firstly, if "ionic.config.js has been deprecated’, can the Ionic team please remove it from the starters so that we don’t get this message every time we install or do a serve, and thus need to delete it ourselves?
My setup is as follows:
Cordova CLI: 6.0.0
Gulp version: CLI version 3.9.1
Gulp local: Local version 3.9.1
Ionic Framework Version: 2.0.0-beta.6
Ionic CLI Version: 2.0.0-beta.25
Ionic App Lib Version: 2.0.0-beta.15
OS: Windows 8.1
Node Version: v5.11.0
npm version is 3.8.8
After doing an ionic serve
in the project directory I am only seeing this in the app.bundle.js:
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
},{}],2:[function(require,module,exports){
arguments[4][1][0].apply(exports,arguments)
},{"dup":1}]},{},[1,2])
//# sourceMappingURL=app.bundle.js.map
and there is nothing between the <ion-app></ion-app>
tags of the HMTL body when live-reloaded into and viewed in Chrome Developer (i.e. the app hasn’t been injected there).
I have tried deleting the node_modules
folder and doing a npm install
but this has not fixed the problem.
I am able to successfully serve a beta4 project with the following package.json
"dependencies": {
"angular2": "^2.0.0-beta.13",
"es6-promise": "3.0.2",
"es6-shim": "^0.35.0",
"ionic-angular": "^2.0.0-beta.4",
"ionic-native": "^1.1.0",
"ionicons": "3.0.0-alpha.3",
"moment": "^2.12.0",
"reflect-metadata": "0.1.2",
"rxjs": "5.0.0-beta.2",
"zone.js": "0.6.6"
},
"devDependencies": {
"del": "2.2.0",
"gulp": "3.9.1",
"gulp-watch": "4.3.5",
"ionic-gulp-browserify-typescript": "^1.0.1",
"ionic-gulp-fonts-copy": "^1.0.0",
"ionic-gulp-html-copy": "^1.0.0",
"ionic-gulp-sass-build": "^1.0.0",
"ionic-gulp-scripts-copy": "^1.0.0",
"run-sequence": "^1.1.5",
"typescript": "1.8.7"
},
Despite this working, in both cases I always get FS and EPERM related errors such as the following when doing an ionic serve
Caught exception:
Error: watch C:\Users\Mark\My Documents\App Development\test2\app\pages\page3\p
age3.scss EPERM
at exports._errnoException (util.js:893:11)
at FSWatcher.start (fs.js:1313:19)
at Object.fs.watch (fs.js:1341:11)
at createFsWatchInstance (C:\Users\Mark\Documents\App Development\test2\node
_modules\chokidar\lib\nodefs-handler.js:37:15)
at setFsWatchListener (C:\Users\Mark\Documents\App Development\test2\node_mo
dules\chokidar\lib\nodefs-handler.js:80:15)
at FSWatcher.NodeFsHandler._watchWithNodeFs (C:\Users\Mark\Documents\App Dev
elopment\test2\node_modules\chokidar\lib\nodefs-handler.js:228:14)
at FSWatcher.NodeFsHandler._handleFile (C:\Users\Mark\Documents\App Developm
ent\test2\node_modules\chokidar\lib\nodefs-handler.js:255:21)
at FSWatcher.<anonymous> (C:\Users\Mark\Documents\App Development\test2\node
_modules\chokidar\lib\nodefs-handler.js:473:21)
at FSReqWrap.oncomplete (fs.js:82:15)
Mind letting us know? https://github.com/driftyco/ionic-cli/issues
but i believe that it maybe a Windows (8) related issue rather than ionic2 specific (albeit I never saw such errors when using ionic1). Or it might be related to the version of graceful-fs
- there is a warning with some dependency during the npm install
that the version of graceful-fs
is deprecated and that ^4.0.0 should be used. I tried installing ^4.0.0 as a dev dependency in my project but that did not fix the FS watcher problems.
Anyway any advice would be appreciated as I’m stuck using my working beta4 project setup at the moment.
EDIT: The following issue is in regards to the deprecated graceful-fs version used by Ionic dependencies: