Issue I have a project management app where the details of the project are displayed after pressing the ‘more’ icon button on a card. The details to be displayed include the project name and due date that are fetched from
Continue readingTag: flutter-sharedpreference
Not able to see sharedpref folder in phone as well Getting this error :Exception has occurred. _CastError (Null check operator used on a null value)
Issue Hello Guys I am new to flutter and working on a flutter project. Below is the code of my splash screen. What I am doing is when the app launched we get the data from sharedpreference if we got
Continue readingSave Bool Switch value with shared preferences – not working
Issue I already followed a few examples on YT and also an example on pub.dev and I still have a problem with saving the Switch value from false to true. Regarding documentation, it looks like everything is ok but still,
Continue readingwhenver i try to login in my app it shows login screen then goes to HomeScreen in flutter?
Issue auth_service.dart import ‘dart:convert’; import ‘package:flutter/material.dart’; import ‘package:http/http.dart’ as http; import ‘package:provider/provider.dart’; import ‘package:shared_preferences/shared_preferences.dart’; import ‘package:zomato_clone/common/widgets/bottom_bar.dart’; import ‘package:zomato_clone/constants/error_handling.dart’; import ‘package:zomato_clone/constants/global_variables.dart’; import ‘package:zomato_clone/constants/utils.dart’; import ‘package:zomato_clone/features/admin/screens/admin_screen.dart’; import ‘package:zomato_clone/models/user.dart’; import ‘package:zomato_clone/providers/user_provider.dart’; class AuthService { // sign up user void signUpUser({ required BuildContext context,
Continue readingFlutter Onboarding Screen Only Once With Splash Screen
Issue I was working in Flutter to make an app and I only want the onboarding screen to be seen once by users. I have watched several videos showing how to do this, but the problem is my home screen
Continue readingIntegrate Provider with SharedPreferences to save and get Provider data
Issue The list which stores the task data is integrated with provider for state management, but once I close the app and reopen it again, all tasks vanish. With resources, I got to know about SharedPreferences. How do I go
Continue readingUnhandled Exception: type 'Null' is not a subtype of type 'List<dynamic>' in type cast
Issue Objective is to convert a String to List using map and return the value to a function call. I am using SharedPreferences to save a list of object called where in I save the data at a point and
Continue readingSharedPreferences automatically get cleared when browser closed for flutter web
Issue SharedPreferences automatically get cleared when browser closed for flutter web. There is no problem when flutter web is reloaded but problem cause when closing browser and again when relaunched Solution SharePrefrences works as expected in production mode, try flutter
Continue readingsharedPreference as future in FutureBuilder not working
Issue In this code I want to check if user is logged in or not. so, reading data from sharedPreference, if it is true then it should build homepage() else build LoginPage(). But output shows circularProgressIndicator, which means snap has
Continue readingFlutter app losing local data when user closes the app
Issue My app uses both shared_preferences and writing to a local json file (getting path using path_provider) for the data that it uses. I recently started testing it (starting 1/1/22) with a larger group and some people are having an
Continue reading