codekit 0.0.3 copy "codekit: ^0.0.3" to clipboard
codekit: ^0.0.3 copied to clipboard

A development kit for Flutter projects, providing common utilities and extensions.

A collection of essential utilities and extensions for Flutter and Dart development, designed to streamline common tasks and enhance productivity.

Features #

  • indentJson function: Formats JSON data with a specified indent.
  • stringify function: Converts various data types to their string representations, handling JSON serialization for Maps and Iterables.

Getting started #

To use codekit, add it to your pubspec.yaml file:

dependencies:
  codekit: ^0.0.3 # Or the latest version

Then, run flutter pub get or dart pub get.

Usage #

indentJson and stringify functions #

import 'package:codekit/codekit.dart';

void main() {
  // Example of indentJson
  final Map<String, dynamic> data = {
    'name': 'Codekit',
    'version': '1.0.0',
    'features': ['indentJson', 'stringify'],
    'nested': {
      'key': 'value'
    }
  };
  print('Indented JSON:');
  print(indentJson(data));

  // Example of stringify
  print('\nStringify a function:');
  print(stringify(() => 'This is from a function'));

  print('\nStringify a list:');
  print(stringify([1, 2, 3]));

  print('\nStringify a string:');
  print(stringify('Hello Codekit!'));

  print('\nStringify null:');
  print(stringify(null));
}

For more examples, see the example folder and lib/src/codekit_example_new.dart.

Additional information #

Feel free to contribute to this package by submitting issues or pull requests on GitHub. Your feedback and contributions are highly appreciated!

1
likes
0
points
166
downloads

Publisher

verified publishervenhdev.me

Weekly Downloads

A development kit for Flutter projects, providing common utilities and extensions.

Repository (GitHub)
View/report issues

License

unknown (license)

More

Packages that depend on codekit