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

Cannot Use camunda-bpmn-js Without Installing @bpmn-io/form-js #333

Open
philippfromme opened this issue Dec 21, 2023 · 6 comments
Open
Labels
backlog Queued in backlog bug Something isn't working

Comments

@philippfromme
Copy link
Contributor

Describe the Bug

I am forced to install @bpmn-io/form-js when using this library due to @bpmn-io/form-variable-provider listing it as a peer dependency and its implementation depending on the getSchemaVariables functionality.

camunda-bpmn-js 🔗 @bpmn-io/form-variable-provider 🔗 @bpmn-io/form-js

Steps to Reproduce

  1. Install this library
  2. @bpmn-io/form-js dependency must be installed

Expected Behavior

I can use this library without having to install @bpmn-io/form-js. Resolving form variables is optional or the functionality of getSchemaVariables is pulled out of bpmn-io/form-js.

@philippfromme philippfromme added the bug Something isn't working label Dec 21, 2023
@philippfromme
Copy link
Contributor Author

@marstamm Are we aware of this?

@marstamm
Copy link
Member

This was caused by bpmn-io/form-variable-provider#4. I guess we were to eager to add peer-dependencies. Form-js should be a direct dependency for the variable resolver. I'll create a patch release

marstamm added a commit to bpmn-io/form-variable-provider that referenced this issue Jan 12, 2024
forms are embedded in the BPMN and available even without form-js

related to camunda/camunda-bpmn-js#333
marstamm added a commit to bpmn-io/form-variable-provider that referenced this issue Jan 12, 2024
forms are embedded in the BPMN and available even without form-js

related to camunda/camunda-bpmn-js#333
@nikku nikku added the backlog Queued in backlog label Jan 15, 2024 — with bpmn-io-tasks
@nikku
Copy link
Member

nikku commented Jan 15, 2024

I'm not a fan of bundling form-js in the context of BPMN and raised this with the HTO team. Maybe we find a better way to inject the code intelligence, if forms are used (and recognized)?

This would also ensure there exists only a single instance of form-js in the tree.

@marstamm
Copy link
Member

I think we are mixing 2 issues here.

  1. This Issue: The variable resolver requires a utility from form-js, but declares it as a peer dependency. We do not want to add form-js as direct dependency (or install it manually) for bpmn-js only bundles and still want the code completion ==> mark it as production dependency fix: make form-js a production dependency bpmn-io/form-variable-provider#6

  2. The bundle then contains everything from form-js, not just the utility function ==> unrelated to the fist one, should be fixed in form-js

nikku pushed a commit to bpmn-io/form-variable-provider that referenced this issue Jan 15, 2024
forms are embedded in the BPMN and available even without form-js

related to camunda/camunda-bpmn-js#333
@nikku
Copy link
Member

nikku commented Jan 15, 2024

The bundle then contains everything from form-js, not just the utility function ==> unrelated to the fist one, should be fixed in form-js

This is what I reached out to HTO about.

@philippfromme
Copy link
Contributor Author

I think shipping the utility as a separate library acknowledging the fact that it's used outside of the context of form-js would make sense. This is how we've handled such cases in the past.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog Queued in backlog bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants