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

Lots of warnings during compile time #507

Open
gappc opened this issue Jan 12, 2024 · 0 comments
Open

Lots of warnings during compile time #507

gappc opened this issue Jan 12, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@gappc
Copy link
Collaborator

gappc commented Jan 12, 2024

When the Data Browser is build, a list of warnings appear that are related to the way SVG icons are loaded.

Steps to reproduce

  • compile the Data Browser with npm run build and take a look at the output

Explanation

All SVG icons in the Data Browser reside in their own components and can be included in components statically through an import or dynamically using the IconParser component.

As result, during compilation a lot of warnings appear stating that when (Icon) components are included statically and dynamically, then those components won't be moved into another chunk.

Example warning:

(!) /home/chris/projects/noi/databrowser/it.bz.opendatahub.databrowser/databrowser/src/components/svg/IconDragAndDrop.vue is dynamically imported by /home/chris/projects/noi/databrowser/it.bz.opendatahub.databrowser/databrowser/src/components/utils/IconParser.vue?vue&type=script&setup=true&lang.ts but also statically imported by /home/chris/projects/noi/databrowser/it.bz.opendatahub.databrowser/databrowser/src/domain/cellComponents/components/utils/editList/table/EditListTable.vue?vue&type=script&setup=true&lang.ts, dynamic import will not move module into another chunk.

The question is, what to do with this warnings.

The IconParser component seems to be used in QuickView components only, and once in the GpsPointMap, although there a static import would suffice.

@sseppi @MatteoBiasi @a-crea what are your opinions?

@gappc gappc added the bug Something isn't working label Jan 14, 2024
@sseppi sseppi added this to the Data Browser 2.6 - Beta milestone Mar 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants