ngx-chips
ngx-chips copied to clipboard
An accessor cannot be declared in an ambient context.
ERROR in node_modules/ngx-chips/components/dropdown/tag-input-dropdown.component.d.ts(92,9): error TS1086: An accessor cannot be declared in an ambient context.
node_modules/ngx-chips/components/dropdown/tag-input-dropdown.component.d.ts(97,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/dropdown/tag-input-dropdown.component.d.ts(110,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/dropdown/tag-input-dropdown.component.d.ts(122,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/dropdown/tag-input-dropdown.component.d.ts(126,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag-input-form/tag-input-form.component.d.ts(69,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag-input-form/tag-input-form.component.d.ts(74,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag-input-form/tag-input-form.component.d.ts(81,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag-input/tag-input.d.ts(126,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag-input/tag-input.d.ts(230,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag-input/tag-input.d.ts(255,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag-input/tag-input.d.ts(355,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag-input/tag-input.d.ts(359,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/components/tag/tag.component.d.ts(72,9): error TS1086: An accessor cannot be declared in an ambient context. 12-Oct-2020 09:02:57 | node_modules/ngx-chips/components/tag/tag.component.d.ts(131,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/core/accessor.d.ts(21,9): error TS1086: An accessor cannot be declared in an ambient context. node_modules/ngx-chips/core/accessor.d.ts(22,9): error TS1086: An accessor cannot be declared in an ambient context.
Angular version:- 7
not able to run the application
For a temporary fix - try specifying an older version in the package.json file.
I changed this (actual version used was 2.2.x)
"ngx-chips": "^2.0.2"
With this (fetches 2.0.2)
"ngx-chips": "~2.0.2"
Also remember to commit your package-lock.json
file to avoid these problems.
Alternatively you can try to upgrade angular and/or typescript.