thiagoelg opened a new pull request, #2512:
URL: https://github.com/apache/incubator-kie-tools/pull/2512

   Closes https://github.com/apache/incubator-kie-issues/issues/1418
   
   To programmatically bundle all the typings required, a new library was used: 
https://github.com/timocov/dts-bundle-generator
   
   This library bundles every type used, including those from external 
packages, into a single `.d.ts` file that can be output alongside the `.js` 
entry files. For that, we had to skip generating .d.ts files during webpack 
bundling, setting `declaration` to `false` on the `tsconfig.json`.
   
   Because in some places [1], we import `.js` or `.html` files directly 
(declaring them as modules via `global.d.ts`), bundling the types was not as 
straightforward as initially considered.
   Thankfully, the library author had some insight on how to solve this issue; 
see https://github.com/timocov/dts-bundle-generator/discussions/232 and 
https://github.com/timocov/dts-bundle-generator/issues/102
   
   [1]:
   - 
https://github.com/apache/incubator-kie-tools/blob/main/packages/kie-editors-standalone/src/bpmn/index.ts#L20
   - 
https://github.com/apache/incubator-kie-tools/blob/main/packages/kie-editors-standalone/src/dmn/index.ts#L20
   - 
https://github.com/apache/incubator-kie-tools/blob/main/packages/dmn-editor-standalone/src/index.ts#L20
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to