manekinekko / angular-web-bluetooth

The missing Web Bluetooth module for Angular
https://manekinekko.github.io/angular-web-bluetooth/
MIT License
195 stars 56 forks source link

Compile error report #42

Closed n1705771 closed 6 years ago

n1705771 commented 6 years ago

I downloaded angular-web-bluetooth. But when I run ng serve --open command, there is a error as below:

ERROR in ./src/app/app.module.ts Module not found: Error: Can't resolve 'C:\Users\angular-web-bluetooth-master\dist\angular-web-bluetooth' in 'C:\Users\angular-web-bluetooth-master\src\app' ERROR in ./src/app/battery-level/battery-level.service.ts Module not found: Error: Can't resolve 'C:\Users\angular-web-bluetooth-master\dist\angular-web-bluetooth' in 'C:\Users\angular-web-bluetooth-master\src\app\battery-level'

Could you please check whey this error happens?

Thanks

manekinekko commented 6 years ago

Hi, could you run npm run build before ng serve and let me know?

n1705771 commented 6 years ago

Thanks Manekinekko when I run npm run build, I get below errors:

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! angular-web-bluetooth-starter@1.0.0 build: ng build angular-web-bluetooth --prod npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the angular-web-bluetooth-starter@1.0.0 build script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm WARN Local package.json exists, but node_modules missing, did you mean to install?

npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\AppData\Roaming\npm-cache_logs\2018-07-13T02_25_28_132Z-debug.log

n1705771 commented 6 years ago

I have Installed npm and angular 6. My procedure is as below: 1.Download angular-web-bluetooth (zip file) into my PC. 2.Extract the folder angular-web-bluetooth-master

3.Run below command from Git bash. $ cd angular-web-bluetooth-master $ ng run build

Then I get the above errors.

n1705771 commented 6 years ago

after reinstall bluetooth module, the issue is fixed. thanks