Node_modules/handsontable/handsontable"' has no exported member 'GridSettings'

Tags: #<Tag:0x00007f8b2a1694e8>

I am facing the issue similar to reported

but when I use handsontable-pro it works fine, I am using both right now for get it working.
here what I am currently importing to get it working.

import { HotTableRegisterer } from ‘@handsontable/angular’;
import { Handsontable } from ‘handsontable-pro’;

public hotSettings: Handsontable.GridSettings = {
data: getData()
}

Above working fine, but when I tried to use it like this.

import { HotTableRegisterer } from ‘@handsontable/angular’;
import * as Handsontable from ‘handsontable’;

its shows the following error.

node_modules/handsontable/handsontable"’ has no exported member ‘GridSettings’.

please help.

Hi @smah80

please share the full demo. It is hard to tell what causes the issues.

Hi,
everything working fine if I am using import Handsontable from ‘handsontable-pro’ in the below code, but when I try to use import from handsontable it will start giving mentioned error.
See if its can help to understand my issue.

import { HttpParams } from ‘@angular/common/http’;
import { Component, ViewChild } from ‘@angular/core’;
import { HotTableRegisterer } from ‘@handsontable/angular’;
import { Handsontable } from ‘handsontable-pro’;

@Component({
selector: ‘app-root’,
template: `


<hot-table [afterInit]=“onAfterInit” [hotId]=“id” [settings]=“hotSettings”>

`,

})
export class TestingHot {

public hotSettings: Handsontable.GridSettings = {
data: getData(),
colHeaders: getCols(),
bindRowsWithHeaders: true,
stretchH: ‘all’,
dropdownMenu: true,
filters: true,
allowRemoveColumn: false,
allowInsertColumn: false,
allowRemoveRow: false,
allowInsertRow: false,
hiddenColumns: {
columns: [0],
indicators: true,
copyPasteEnabled: true
},
cells(row, col) {
const cp = { readOnly: false, type: undefined, source: undefined };
if (col > -1 && col < 3) {
cp.readOnly = true;
} else if (col === 7) {
cp.type = ‘dropdown’;
cp.source = [‘NEW’, ‘USED’, ‘OLD’];
}
return cp;
}
};

public getData() {
return [
[“1”,“Tesla”, “Model 3”, “BlueStar”, “USA”, “★★★★”,“NEW”],
[“2”,“Tesla”, “Model S”, “WhiteStar”, “USA”, “★★★★★”,“NEW”],
[“3”,“Mitsubishi”, “iMiEV”, “”, “Japan”, “★★”,“NEW”],
[“4”,“Ford”, “Focus EV”, “”, “USA”, “★★”,“NEW”],
[“5”,“Mitsubishi”, “iMiEV Sport”, “”, “Japan”, “★★”,“NEW”],
[“6”,“Tesla”, “Roadster”, “DarkStar”, “USA”, “★★★★★”,“USED”],
[“7”,“Volkswagen”, “e-Golf”,"", “Germany”, “★★”,“USED”],
[“8”,“Volkswagen”, “E-Up!”, “”, “Germany”, “★★”,“NEW”],
[“9”,“Ford”, “C-Max Energi”, “”, “USA”, “★”,“NEW”],
[“10”,“BYD”, “Denza”, “”, “China”, “★★★”,“OLD”],
[“11”,“BYD”, “e5”, “”, “China”, “★★★”,“NEW”],
[“12”,“BYD”, “e6”, “”, “China”, “★★★★”,“NEW”]
];

}

public getCols() {
return [“id”,“Brand”, “Model”, “Code name”, “Country of origin”, “Rank”,“Status”];
}
}

Please download this Angular project https://we.tl/t-UVnc5Ari7o it uses your settings that work in the latest version 7.2.2 (with PRO features)

Its still not working for me after upgrade to 7.2.2. giving the same error.
/node_modules/handsontable/handsontable"’ has no exported member ‘GridSettings’.ts(2694)

and does my demo run on your device?

No, as I am using npm

Hi @smah80

If you own an Extended Support plan please share a demo build version of your app, wothout the sensitive data) to support@handsontable.com