Ali-Azmoud / flutter_xlider

A material design slider and range slider with rtl support and lots of options and customization for flutter
https://pub.dartlang.org/packages/flutter_xlider
MIT License
519 stars 184 forks source link

Flutter still unable to recognize package as null-safety #112

Open leekaimun opened 3 years ago

leekaimun commented 3 years ago

environment: sdk: ">=2.12.0 <3.0.0"

dependencies: flutter_xlider: ^3.4.0-dev.3

During flutter build, it still complains that the package is not null-safe.

lroige commented 3 years ago

Please @Ali-Azmoud update pub version so that the already merged null-safe version is available for all.

ydotmalik commented 3 years ago

To workaround this, I downloaded the git repo, put it in the top-level directory of my project, and put the following in pubspec.yaml:

  flutter_xlider:
    path: flutter_xlider

The null safety error is no longer happens.

lroige commented 3 years ago

My solution is to import the library using the github url instead of the version number. In production environment, though, this is not desirable, so it would be best to have the new version marked as such.

yanivshaked commented 3 years ago

@Ali-Azmoud Can you please release the latest version of the plugin with null safety support?

ydotmalik commented 3 years ago

Even when I used the null compatible version from master, this package has issues regarding the selectable region of the thumb. I ended up building my own slider by following this answer. It really wasn't much more difficult than using this package.

tsvillain commented 3 years ago
flutter_xlider:
  git:
    url: https://github.com/Ali-Azmoud/flutter_xlider.git
    ref: master

Master branch supports Null Safety but the pub version has not been updated use this.