Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vue wrapper build script fails with Vue 2.7 #9624

Open
budnix opened this issue Jul 4, 2022 · 8 comments
Open

Vue wrapper build script fails with Vue 2.7 #9624

budnix opened this issue Jul 4, 2022 · 8 comments
Assignees
Labels
Reported Tools Tools like NPM, Webpack, Babel, GitHub Workflows

Comments

@budnix
Copy link
Member

budnix commented Jul 4, 2022

Description

Using the latest installation (npm i) on the repo and trying to build the Vue wrapper (npm run in vue build) the script fails.

The error message:

./src/index.ts → ./commonjs/vue-handsontable.js...

[!] (plugin rpt2) Error: /Users/budnix/Documents/Projects/handsontable/wrappers/vue/src/HotTable.vue?rollup-plugin-vue=script.ts(30,5): semantic error TS2322: Type '{ name: string; props: VueProps<HotTableProps>; watch: { mergedHotSettings: (value: any) => void; }; data: () => { __internalEdit: boolean; miscCache: { currentSourceColumns: any; }; ... 4 more ...; hotInstance: any; }; ... 4 more ...; version: any; }' is not assignable to type 'HotTableComponent<Vue, HotTableData, HotTableMethods, {}, HotTableProps>'.
  Object literal may only specify known properties, and 'name' does not exist in type 'HotTableComponent<Vue, HotTableData, HotTableMethods, {}, HotTableProps>'.
src/HotTable.vue?rollup-plugin-vue=script.ts

or

./src/index.ts → ./commonjs/vue-handsontable.js...

[!] (plugin rpt2) Error: /Users/budnix/Documents/Projects/handsontable/wrappers/vue/src/HotColumn.vue?rollup-plugin-vue=script.ts(14,20): semantic error TS2314: Generic type 'ThisTypedComponentOptionsWithRecordProps' requires 6 type argument(s).

I've checked the latest version of the wrapper with the Vue CLI and it seems that the issue is about the build dependencies mismatch on the build side and not about the dependencies mismatch on the developers' app side.

Your environment

  • Handsontable version: -
  • Browser name and version: -
  • Operating system: -
@maksim-shila
Copy link

maksim-shila commented Jul 5, 2022

Handsontable not compatible with vue 2.7 since ThisTypedComponentOptionsWithRecordProps takes one more generic argument

image

Do you plan to update?

EDIT: vue released only 4 days ago https://github.com/vuejs/vue/releases

@budnix
Copy link
Member Author

budnix commented Jul 5, 2022

@maksim-shila I wonder if you have the error only while building the component within monorepo? Or the same error is thrown in Vue 2.7 app that uses the official @handsontable/vue package?

@maksim-shila
Copy link

Here is example of project with this error
example.nuxt.zip

Only adding exact version of vue to package.json did the trick
"vue": "2.6.14", "vue-server-renderer": "2.6.14", "vue-template-compiler": "2.6.14"

@aninde
Copy link
Contributor

aninde commented Jul 8, 2022

npm run in vue build works after npm i with LTS node v16.15.1, npm v8.11.0 with v12.1.2 200cca2.

@warpech warpech changed the title Vue wrapper build script fails Vue wrapper build script fails with Vue 2.7 Jul 8, 2022
@warpech
Copy link
Member

warpech commented Jul 8, 2022

@maksim-shila we will investigate the problem.

This issue is about a failure with Vue 2.7 in our build chain, which caused us to temporarily downgrade the version used in our build chain to Vue 2.6.

Nevertheless, we verified that in normal conditions Handsontable can be used with Vue 2.7 (including TypeScript), so your problem is something that we yet have to investigate.

@AMBudnik AMBudnik added Status: Released Tools Tools like NPM, Webpack, Babel, GitHub Workflows labels Jul 11, 2022
@AMBudnik
Copy link
Contributor

AMBudnik commented Jul 11, 2022

Closed as solved in Handsontable v12.1.2

@warpech
Copy link
Member

warpech commented Jul 12, 2022

@maksim-shila if you still experience the problem, please contact support@handsontable.com.

@budnix budnix reopened this Jul 13, 2022
@budnix
Copy link
Member Author

budnix commented Jul 13, 2022

I reopened the issue as the bug still exists. The related PR solves the problem but currently, the change is not backward compatible with Vue 2.6 so it needs to be investigated to support all Vue ^2 semver range versions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Reported Tools Tools like NPM, Webpack, Babel, GitHub Workflows
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants