EPA-WG / custom-element

Declarative Custom Element
Apache License 2.0
22 stars 1 forks source link

add VS Code and JetBrains IDE support #36

Closed break-stuff closed 4 months ago

break-stuff commented 9 months ago

This is a simple demonstration of how to add IDE support for DCEs.

This PR includes the CEM/Analyzer as well as plugins to generate the needed files VS Code and JetBrains IDE support.

The component definitions are in the components.js file. these are for documentation purposes only and shouldn't be used in production (also, they are necessary since you are using DCEs).

To generate the necessary config files for the editors, run npm run analyze. This will generate the vscode.html-custom-data.json and web-types.json.

sashafirsov commented 9 months ago

The DCE source project uses static web-types.json , added in 0.0.17. The custom elements are not part of delivery, hence there is no need it on this project. Instead, they would be needed in custom-element-bootstrap. Moving the code for IDE support there.

break-stuff commented 8 months ago

@sashafirsov Would you like me to create a PR for this there?

sashafirsov commented 8 months ago

@break-stuff , thanks for offer. The code which generates those files reside in https://github.com/EPA-WG/dce-parser/ and applied to this project. As of now they are up to date and no need for PR to this repo.

The bootstrap project need to be updated though. But it is a bit outdated in terms of attributes and slots support. Once the slots handling polished, the custom-element-bootstrap would need samples and updates for metadata.

sashafirsov commented 4 months ago

The intermediate VSCode and IntelliJ config files are code generated by test proj and added to the main branch. Closing this PR as outdated.