1

So I was trying to add flutter_widget_from_html and better_player together in my flutter app but they are incompatible with each other.

This was the error message:

C:\srcc\flutter\bin\flutter.bat --no-color pub get
Running "flutter pub get" in my_app_name...
Resolving dependencies...
Because flutter_widget_from_html >=0.10.0 depends on flutter_widget_from_html_core ^0.10.0 and better_player 0.0.83 depends on flutter_widget_from_html_core ^0.8.5+3, flutter_widget_from_html >=0.10.0 is incompatible with better_player 0.0.83.
And because no versions of better_player match >0.0.83 <0.1.0, flutter_widget_from_html >=0.10.0 is incompatible with better_player ^0.0.83.
So, because my_app_name depends on both better_player ^0.0.83 and flutter_widget_from_html ^0.10.0, version solving failed.
pub get failed
command: "C:\src\flutter\bin\cache\dart-sdk\bin\dart __deprecated_pub --directory . get --example"
pub env: {
  "FLUTTER_ROOT": "C:\srcc\flutter",
  "PUB_ENVIRONMENT": "flutter_cli:get",
  "PUB_CACHE": "C:\Users\THIS PC\AppData\Local\Pub\Cache",
}
exit code: 1

Process finished with exit code 1

Can someone help me identify a way to integrate these two or any other solution if available?

im_jm
  • 11
  • 3

1 Answers1

0

Try using downgrading to this version
flutter_widget_from_html: 0.8.5

Make sure to not use ^ symbol before version

siffat
  • 13
  • 6
  • Ended up using 'webview_flutter: ^4.2.0' as I needed a null-safe version. Thanks for your input. – im_jm May 15 '23 at 09:23