alxhub / io17

106 stars 21 forks source link

Failed to run ngu-sw-manifest #2

Open chaoranxie opened 7 years ago

chaoranxie commented 7 years ago

I am using hammerjs in my project so there is this line in the app module file. import 'hammerjs'; any idea what i need to do? i thought hammerjs is a pretty common library to include

./node_modules/.bin/ngu-sw-manifest --module src/app/app.module.ts

/Users/chaoranxie/dev/cwm/node_modules/hammerjs/hammer.js:2643
})(window, document, 'Hammer');
   ^
ReferenceError: window is not defined
    at Object.<anonymous> (/Users/chaoranxie/dev/cwm/node_modules/hammerjs/hammer.js:2643:4)
    at Module._compile (module.js:570:32)
    at Object.Module._extensions..js (module.js:579:10)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12)
    at Function.Module._load (module.js:438:3)
    at Module.require (module.js:497:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/Users/chaoranxie/dev/cwm/src/app/app.module.ts:16:1)
    at Module._compile (module.js:570:32)
cars10 commented 7 years ago

I experience the same issue. Any updates ?

abnersouza commented 7 years ago

any updates? Im getting this issue with Jquery library installed as well.

fopnet commented 5 years ago

i am using ngu-sw-manifest --module src/app/app.module.ts

and i ve got the same error using

hammerjs@^2.0.8.

How can i solve this?