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

Unify declaration of third-party dependencies #2991

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

falkoschindler
Copy link
Contributor

@falkoschindler falkoschindler commented Apr 30, 2024

Currently there are three ways to include JavaScript libraries when subclassing UI elements: libraries, exposed_libraries and extra_libraries. This PR experiments with using exposed_libraries only, which seems to work for all elements. A new "signature pad" example demonstrates how to use NPM to define and install JavaScript dependencies in a NiceGUI project.

Open tasks:

  • deprecate libraries and extra_libraries parameters?
  • replace exposed_libraries with a more intuitive name?
  • demonstrate a more complex NPM example, like vue-signature-pad, which has other dependencies? --> No, there's currently no point in trying to integrate third-party Vue components since we're not able to support Vue 3 components at the moment.
  • demonstrate a more complex NPM example, like is-odd, using a bundler (see the new "is even" example)
  • add some documentation about custom UI elements with third-party dependencies

@falkoschindler falkoschindler added the enhancement New feature or request label Apr 30, 2024
@falkoschindler falkoschindler added this to the 2.0.0 milestone Apr 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant