Angular 9 how to fix export 'CDK_TABLE' was not found in '@angular/cdk/table

Stumbled on this too. Turns out the packages got de-synced somehow in packages.json.

Make sure you have latest version for all: 9.20 for material packages:

"@angular/material": "^9.2.0",
"@angular/cdk": "^9.2.0",

Also, update your @angular packages to 9.1.0 (command depends on your package manager).


Using npm install @angular/cdk --save should resolve this.


An important note is that most material components have individual paths now, so in case your imports looks like import {MatTableModule} from '@angular/material' you should change them to import {MatTableModule} from '@angular/material/table'; or import {CdkTableModule} from '@angular/cdk/table';

As I have upgraded a project to v9 I can confirm that the other 3 imports (

import { MatPaginator } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatTableDataSource } from '@angular/material/table';

) look ok.

Hope it helps