Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/skipness/lzstring-dart

Dart implementation of lz-string compression algorithm
https://github.com/skipness/lzstring-dart

compression dart dartlang lzstring

Last synced: about 1 month ago
JSON representation

Dart implementation of lz-string compression algorithm

Awesome Lists containing this project

README

        

# lzstring
[![Pub](https://img.shields.io/badge/pub-v2.0.0%2B2-blue.svg)](https://pub.dartlang.org/packages/lzstring)

Dart implementation of lz-string compression algorithm

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

## Usage
```dart
Future compressedString = LZString.compress('Some String');
Future decompressedString = LZString.decompress(compressedString);

String? compressedStringSync = LZString.compressSync('Some String');
String? decompressedStringSync = LZString.decompressSync(compressedStringSync);
```
For more usage, please read the exapmle in [example](https://github.com/skipness/lzstring-dart/tree/master/example) folder

## Running test
```
pub run test test/lz_string.dart
```