Ionic@rc.1 - @ionic/app-scripts 0.0.31/2/3 problem


#1

Hello,

After upgrade to ionic2 rc1 I started to have 2 errors:

ionic serve started to throw errors in *.spec.ts files, that cannot find name ‘it’ and ‘describe’…
@ionic/app-scripts 0.0.30 were fine. I did workaround by importing ‘mocha’ in app.component.ts and this type of errors disapreared.

now i am getting error like this:
[08:24:37] rollup: Treating ‘fs’ as external dependency

[08:24:37]  rollup: Treating 'child_process' as external dependency

[08:24:40]  rollup: No name was provided for external module 'fs' in options.globals – guessing 'fs'

[08:24:40]  rollup: No name was provided for external module 'child_process' in options.globals – guessing
            'child_process'

main.js is created, but browser thorws error:

browser-entry.js:166
Uncaught ReferenceError: fs is not defined(anonymous function) @ browser-entry.js:166

Do anybody have any suggestion how to solve these errors?

Thanks


#2

Hi,

we have same problem with spec.ts files too. Any help is really appreciated.

Thanks


#3

I reported it. It will be fixed.


#4

Please update to app-scripts 0.0.33 .

npm install @ionic/app-scripts@latest --save-dev

#5

Hi Mike, I just installed the latest app-scripts (0.0.34) and ionic serve still seems to check the spec files?

[06:29:09]  typescript: src/pages/login/login.spec.ts, line: 44 
            Cannot find name 'it'. 

      L44:  it('login', () => {

[06:29:09]  typescript: src/pages/login/login.spec.ts, line: 48 
            Cannot find name 'expect'. 

      L48:  expect(true).toBe(true);

#6

I am using 0.0.46 still ionic app scripts not able to find jasmine keywords,I have installed jasmine typings and include visual code but don’t know how to include in ionic app scripts.This problem exists in windows 7.