json_compressor 1.0.0

  • README.md
  • Installing
  • Versions
  • 42


provides a transformer that compresses json files


json_compressor provides two parameters: 'debugMode' and 'prodMode', both are optional.

  json_compressor: ^1.0.0
- json_compressor:
    debugMode: indent1
    prodMode: no_indent

possible values (for both)

  • off: don't change the json files (this is also the fallback, if an illegal value was provided)
  • single_row: compress json file to a singleline version without spaces or newlines
  • no_indent: compress json file to a multiline version without indentation/spaces
  • indent1: compress json file to a multiline version with one space indentation per level
  • indent2: compress json file to a multiline version with two spaces indentation per level
  • indent4: compress json file to a multiline version with four spaces indentation per level

default values

  • debugMode: no_indent
  • prodMode: single_row



  • Initial version with a functional json compressing transformer

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  json_compressor: "^1.0.0"

2. Install it

You can install packages from the command line:

with pub:

$ pub get

with Flutter:

$ flutter packages get

Alternatively, your editor might support pub get or flutter packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

      import 'package:json_compressor/transformer.dart';
Version Uploaded Documentation Archive
1.0.0 Feb 5, 2017 Go to the documentation of json_compressor 1.0.0 Download json_compressor 1.0.0 archive


We analyzed this package on Jun 12, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.0.0-dev.60.0
  • pana: 0.11.3


Describes how popular the package is relative to other packages. [more]
0 / 100
Code health derived from static analysis. [more]
96 / 100
Reflects how tidy and up-to-date the package is. [more]
65 / 100
Overall score:
Weighted score of the above. [more]
Learn more about scoring.


Detected platforms: Flutter, web, other

Platform components identified in package: build.


  • Package is getting outdated.

    The package was released 70 weeks ago.

  • Maintain an example.

    Create a short demo in the example/ directory to show how to use this package. Common file name patterns include: main.dart, example.dart or you could also use json_compressor.dart.

  • Fix analysis and formatting issues.

    Analysis or formatting checks reported 2 hints.

    Run dartfmt to format lib/transformer.dart.

  • Use analysis_options.yaml.

    Rename old .analysis_options file to analysis_options.yaml.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.12.0 <2.0.0
barback ^0.15.2+9 0.15.2+16
Transitive dependencies
async 2.0.7
charcode 1.1.1
collection 1.14.10
path 1.6.0
pool 1.3.5
source_span 1.4.0
stack_trace 1.9.2