I am trying to save the data locally in my application trying to use the shared preferences, while on android and chrome everything is ok, on ios by problems. When I debug with xcode this warning comes out "shared_preferences_ios not found".
https://i.stack.imgur.com/20YnV.png
CodePudding user response:
Follow this steps
- Backup ios/Runner folder.
- Delete the ios folder.
- Run flutter create (your project name). in the previous folder where you have your project(cd users/user/"projects_folder") (this will recreate your ios folder).
- Paste your Runner backup in the ios folder (into the project).
- Open Runner.xcworkspace (into ios folder) and there, check the Version, the Bundle ID, all the info.
- (If do you Have Firebase, you have to copy and paste again the Google Service-Info.Plist into the Runner folder (Always through Xcode) (If do you do this manually, it doesn't work). Finally, flutter run and should work! If flutter run fails:
- cd ios
- pod install
- cd ..
- flutter run