Hello,
Currently I am having the following error "TypeError: Cannot set property 'align' of undefined" as I run karma test with any components that make use of the CurrencyMaskModule.
I am using Angular 6 and the v5.3.1 of ng2-currency-mask.
The error disappears as I comment line 33 of the currency-mask.directive.js
this.elementRef.nativeElement.style.textAlign = this.options.align ? this.options.align : this.optionsTemplate.align;
This issue only appears with ng test but nothing wrong with the ng serve.
Any ideas?
There's an issue in the original project about this problem, and there are instructions to deal with it. They could be implemented in this fork.
Migrated from original project (https://github.com/cesarrew/ng2-currency-mask/issues/123) - Follow to find the fix.
Orignal request by @diegotakeo
Hello, Currently I am having the following error "TypeError: Cannot set property 'align' of undefined" as I run karma test with any components that make use of the CurrencyMaskModule.
I am using Angular 6 and the v5.3.1 of ng2-currency-mask.
The error disappears as I comment line 33 of the currency-mask.directive.js this.elementRef.nativeElement.style.textAlign = this.options.align ? this.options.align : this.optionsTemplate.align;
This issue only appears with ng test but nothing wrong with the ng serve. Any ideas?