14

I am using Ng2SmartTable and I have this error:

ERROR in The target entry-point "ng2-smart-table" has missing dependencies: - @ akveo / ng2-completer

I have already tried the following commands and it does not work:

1.npm install --save ng2-smart-table

2.npm i ng2-completer --save

3.npm i rxjs-compat --save

Vignesh A
  • 289
  • 7
  • 19
NicoGuevaraAtuq
  • 502
  • 2
  • 5
  • 17

10 Answers10

6

uninstall by using below command:-

npm uni @akveo/ng2-completer

install by using below command:-

npm i ng2-completer

It solve my problem !!

For further detail:- https://github.com/akveo/ng2-smart-table/commit/59c3a7885591f1e003dbd67fa80844d187a89244

Kartik Chandra
  • 390
  • 4
  • 9
3

just a heads up if you're upgrading ng-smart-table to v.1.7.0, there is a BREAKING change with the ng2-completer package, see https://github.com/akveo/ng2-smart-table/commit/59c3a7885591f1e003dbd67fa80844d187a89244

3
    npm install ng2-smart-table
    npm install ng2-completer

If still don't work: delete node_module/ folder (install dependencies again)

    npm install
rohit.khurmi095
  • 2,203
  • 1
  • 14
  • 12
2

try this.

npm i rxjs-compat --save
npm i @akveo/ng2-completer --save

See here. https://github.com/yggg/ng2-smart-table/commit/8a4f0bb

As mentioned above, you need to be careful.

  • 1
    Didnt work, but I found that the following did npm i rxjs-compat --save npm i ng2-completer --save – JMG Nov 14 '20 at 00:37
1

Installing the dependencies makes it work in dev, but in the build prod there is a problem.

For Angular 9+ try this:

in your tsconfig.app.json, set

 "angularCompilerOptions": {
    "enableIvy": true
  }

its worked for me, with @akveo/ng2-completer dependency only.

Lucas Simões
  • 589
  • 5
  • 10
1

For this version

"ng2-smart-table": "^1.6.0"

I had to run

npm install --save ng2-completer

because version 1.6.0 use require('ng2-completer') instead of require('@akveo/ng2-completer')

octavian09
  • 139
  • 1
  • 3
1

at the moment, i also installed both

ng2-smart-table at 1.7.2
@akveo/ng2-completer at 9.0.1

i found a problem when used ng2-smart-table at 1.7.2

so, i downgraded ng2-smart-table to 1.6.0.

it seems work for me.

Tanandara
  • 11
  • 1
0

I also faced the same issue while trying to install ng2-smart-table

In ng2-smart-table the CompleterService is imported in the following way

import { CompleterService } from '@akveo/ng2-completer';

But if we open ng2-completer from node_modules you can see the ng2-completer is not within the '@akveo' folder

So just create a new folder in node_module and rename it as @akveo and copy the ng2-completer files into @akevo folder

Now open package.json , package.lock.json and change ng2-completer to @akveo/ng2-completer and restart the server

it will be working fine

Thanks

Vignesh A
  • 289
  • 7
  • 19
0

For my Angular 11 project, I got it solved by installing following two packages to get ng2-smart-table running:

npm i ng2-smart-table --save

npm i ng2-completer --save

MHS
  • 1
-1

Try this: npm install ng2-completer --save-dev

More details are available here

kissu
  • 40,416
  • 14
  • 65
  • 133