Skip to content

Commit a906384

Browse files
author
skipness
authored
doc: update README.md
1 parent e645a83 commit a906384

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

README.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,17 @@
11
# lzstring
2-
[![Pub](https://img.shields.io/badge/pub-v1.0.3%2B1-blue.svg)](https://pub.dartlang.org/packages/lzstring)
2+
[![Pub](https://img.shields.io/badge/pub-v2.0.0%2B2-blue.svg)](https://pub.dartlang.org/packages/lzstring)
33

44
Dart implementation of lz-string compression algorithm
55

66
The original JavaScript version is [here](https://github.com/pieroxy/lz-string)
77

88
## Usage
99
```dart
10-
Future<String> compressedString = LZString.compress('Some String');
10+
Future<String?> compressedString = LZString.compress('Some String');
1111
Future<String?> decompressedString = LZString.decompress(compressedString);
12+
13+
String? compressedStringSync = LZString.compressSync('Some String');
14+
String? decompressedStringSync = LZString.decompressSync(compressedStringSync);
1215
```
1316
For more usage, please read the exapmle in [example](https://github.com/skipness/lzstring-dart/tree/master/example) folder
1417

0 commit comments

Comments
 (0)