Issue
I installed a flutter package, played around with the package’s source code, modified it a bit, then I proceeded to remove the file from my project via pubspec. But now even after removing the package, when I re-installed the flutter package, edits I made previously in the package source code still remains. Please how do I fix this?
Solution
As the packages are cached in your system automatically, it is not enough to delete it from your pubspec.yaml file but you have to also manually delete it from your system.
If you are using Windows, the path to the cached packages from https://pub.dev/ is C:\Users{User}\AppData\Roaming\Pub\Cache\hosted\pub.dartlang.org.
Another option would be to run flutter packages cache repair
if you are using flutter or pub cache repair
if you are developing in dart.
I hope this helps!
Answered By – Francisco Javier Snchez
Answer Checked By – Dawn Plyler (FlutterFixes Volunteer)