1
votes

I am using ngx-bootstrap 1.9.2 npm package, but when I try to compile, my project, angular throws following error:

ERROR in C:/xxx/xx/node_modules/ngx-bootstrap/datepicker/bs-datepicker.component.d.ts (46,15): Cannot find name 'Partial'.

ERROR in C:/xxx/xx/node_modules/ngx-bootstrap/datepicker/bs-daterangepicker.component.d.ts (45,15): Cannot find name 'Partial'.

As Partial was introduced in ts version 2.1, I tried upgrading typescript version from 2.0.0 to 2.5.2 nothing helped.

3

3 Answers

0
votes

we use typescript 2.4.2, because it's mandatory for angular@5. What can help:

0
votes

It was just cache issue, I just perform npm cache clean and performed clean install and my problem was solved.

By the way thanks all, for your comments and answers.

0
votes

For me it worked after doing the following steps.

  1. install the latest typescript version globally. use below command. npm install -g typescript@latest
  2. Clean the npm cache using
    npm clean cache
  3. Install the latest typescript locally. npm install -g typescript@latest

And it worked for me. Hope it helps.