2021-06-01 22:50:34 +07:00
|
|
|
# CUBETIQ Dart Shared
|
|
|
|
A minimal dart functions, utils and extensions for CUBETIQ Developers.
|
|
|
|
|
|
|
|
# Features
|
|
|
|
- Configurable
|
|
|
|
- Text Formatter
|
2021-06-01 19:41:14 +07:00
|
|
|
|
|
|
|
## Usage
|
|
|
|
|
2021-06-01 22:50:34 +07:00
|
|
|
A simple configurable usage example:
|
2021-06-01 19:41:14 +07:00
|
|
|
|
|
|
|
```dart
|
2021-06-01 22:50:34 +07:00
|
|
|
import 'package:cubetiq/configurable.dart'
|
|
|
|
show
|
|
|
|
SystemConfig,
|
|
|
|
getConfigOrNull,
|
|
|
|
SimpleConfigurationProvider,
|
|
|
|
setConfig;
|
2021-06-01 19:41:14 +07:00
|
|
|
|
|
|
|
main() {
|
2021-06-01 22:50:34 +07:00
|
|
|
SystemConfig.setProvider(SimpleConfigurationProvider());
|
|
|
|
setConfig('hello', 'Be the World!');
|
|
|
|
|
|
|
|
var title = getConfigOrNull('hello', defaultValue: 'Just Hello');
|
|
|
|
print(title); //output will be: Be the World
|
2021-06-01 19:41:14 +07:00
|
|
|
}
|
|
|
|
```
|
|
|
|
|
2021-06-01 22:50:34 +07:00
|
|
|
|
|
|
|
## Contributors
|
|
|
|
- Sambo Chea <sombochea@cubetiqs.com>
|
|
|
|
|
2021-06-01 19:41:14 +07:00
|
|
|
## Features and bugs
|
|
|
|
|
|
|
|
Please file feature requests and bugs at the [issue tracker][tracker].
|
|
|
|
|
2021-06-01 22:50:34 +07:00
|
|
|
[tracker]: https://git.cubetiqs.com/CUBETIQ/cubetiq_dart_shared/issues
|