Select to view content in your preferred language

ExBuilder 1.9: Issue with TypeScript Definitions

698
1
Jump to solution
07-25-2022 03:14 AM
ChristineWiltawsky1
Occasional Contributor

My VS Code can't resolve the Type Definitions from all the jimu packages.

ChristineWiltawsky1_0-1658743738466.png

I can run the command npm start in client-folder and everything is compiled the right way. So I can use my widgets in ExBuilder DevEdition 1.9.

However it is very difficult to code with all the errors in the editor window and without code completion, type safety and all other advantages of TypeScript.

0 Kudos
1 Solution

Accepted Solutions
ChristineWiltawsky1
Occasional Contributor

I found a solution: My widgets are in a own exb-web-extension-repo, and not in the your-extensions folder. If I add this folder to the include array in tsconfig.json, everything works fine.

"include": [
    "dist/widgets",
    "your-extensions",
    "types",
    "jimu-core/lib/types",
    "ExB-samples"
  ],
This param was obviously added to tsconfig with 1.9. Would be great if you can add this to the What's new documentation. @Jianxia 

View solution in original post

1 Reply
ChristineWiltawsky1
Occasional Contributor

I found a solution: My widgets are in a own exb-web-extension-repo, and not in the your-extensions folder. If I add this folder to the include array in tsconfig.json, everything works fine.

"include": [
    "dist/widgets",
    "your-extensions",
    "types",
    "jimu-core/lib/types",
    "ExB-samples"
  ],
This param was obviously added to tsconfig with 1.9. Would be great if you can add this to the What's new documentation. @Jianxia