-
Notifications
You must be signed in to change notification settings - Fork 159
Cannot make package that is both a flutter plugin, and has a dart-only side also #8656
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
Comments
This is a known issue, cc @jonasfj Somewhat related, also about surfacing supported platforms from hooks: |
You can override the detected list of supported platforms by explicitly declaring them: https://pub.dev/help/scoring#:~:text=Declaring%20platforms%3A |
Thanks! Any way to specifically declare dart compatibility too? |
No, we haven't yet figured out how to make packages that are flutter plugins sometimes and dart ffi apps sometimes. Currently the best (but perhaps unsatisfying) advice is to make two separate plugins. |
It seems the main hold-up on this is the analyzer forcing the use of flutter pub get when a nested dep relies on a flutter package. If the nested check was disabled or a flag to disable it was introduced, wouldn't these flow as dart packages? Yes my package nests a web dependency that relies on flutter, native never uses this package so it is never called and should validate as dart. |
I recently published an update to the package https://pub.dev/packages/minigpu. Before this update, I was using plugins for all platforms, but with 1.0.1 I migrated the library to use native assets. Now that I have published this version, only web shows up for compatibility per the pub.dev analyzer.
This package should show as dart compatible and support all native platforms + web. I am only using a plugin now for web, native assets use the new build hook.
Is there any way to force this until recognition of native assets can be added to the analyzer?
cc: @dcharkes
The text was updated successfully, but these errors were encountered: