nfc-pcsc icon indicating copy to clipboard operation
nfc-pcsc copied to clipboard

not working with angular 6 while importing

Open vamsideepak opened this issue 6 years ago • 1 comments

it is not working with angular 6 and it throwing error while importing like "nfc is not a constructor".

import {NFC} from 'nfc-pcsc' throwing error

ERROR in ./node_modules/bindings/bindings.js Module not found: Error: Can't resolve 'fs' in 'C:\Users\Admin\Desktop\electronapp\node_modules\bindings' ERROR in ./node_modules/bindings/bindings.js Module not found: Error: Can't resolve 'path' in 'C:\Users\Admin\Desktop\electronapp\node_modules\bindings'

reason i found fs module will not work with angular 6. by inbuilt nfc containing fs .

because of these reason i accessed nfc from html and i declared in angular 6 component like "declare var NFC: any; " because of above i am getting nfc is not a constructor

vamsideepak avatar Oct 08 '18 10:10 vamsideepak

@vamsideepak what do you exactly mean for "i accessed nfc from html"

I can't use in a regular Angular 7 application and can't release how do you solve the problem. Thanks in advance

Canos avatar May 03 '19 22:05 Canos