Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dreamsoftin/obscured_preferences
Flutter Obscured Preferences
https://github.com/dreamsoftin/obscured_preferences
Last synced: about 2 months ago
JSON representation
Flutter Obscured Preferences
- Host: GitHub
- URL: https://github.com/dreamsoftin/obscured_preferences
- Owner: dreamsoftin
- License: mit
- Created: 2019-04-17T05:46:35.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2021-11-23T14:04:54.000Z (about 3 years ago)
- Last Synced: 2023-08-20T22:50:56.498Z (over 1 year ago)
- Language: Dart
- Size: 98.6 KB
- Stars: 2
- Watchers: 2
- Forks: 4
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# obscured_preferences
This package makes use of [shared_preferences](https://pub.dartlang.org/packages/shared_preferences) and [encrypt](https://pub.dartlang.org/packages/encrypt) packages to provide encrypted shared preferences.
## Usage
The syntax and usage of this package is the same as that of [shared_preferences](https://pub.dartlang.org/packages/shared_preferences).
```dart
import 'package:flutter/material.dart';
import 'package:obscured_preferences/obscured_preferences.dart';void savePrefs() async {
ObscuredPrefs prefs = await ObscuredPrefs.getInstance();
await prefs.setString('key', 'Hello World!');
final strValue = prefs.getString('key');
}
```