- Now can detect fractional seconds.
- Fixed lint error for non-nullable typecast to the nullable type for JSON parser.
- Added better equality operator with
DeepCollectionEquality
from the Dart collection.
- Updated failing build scripts.
- Bugfix and syntaxt corecction.
- Added possibility to implement JSON converter,
encode/decode
inside thetoJson/fromJson
methods. Also will be added extra methods toMap/fromMap.
- Bugfix for windows.
- Bugfix.
- Bugfix.
- Added support for safe
JSON
. The generator can read and parsejson
andjsonc
from any method. - Added support for multiple files conversion. The generator can read
**.json
and**.jsonc
files from the tracked file or directory. - Added a better method for writing files from the context or file explorer.
- Added option to override from/to suffix.
- Added option to avoid
dynamic
types. Generator will generatedynamic
types asObject
with null safety check. - Improved conversion performance. 5X faster speed.
- Bugfix.
- Bugfix.
- Hotfix. Does not generate a new model after deleted.
- Added method to generate models from the
models.jsonc
file after detected newly added JSON objects.
- Implemented faster equality operator.
- Added new option include if null for the
fromJson
method.
- Improved double values conversion.
- Added possibility to override the default path with a new one by adding
__path
key by working with models.jsonc file. Example:"__path": "/lib/models/user"
.
- Bugfix.
-
Added support to force new type for key.
Example:
{ "userPost.post": { "id": 1, "description": "Json To Dart Model", "completed": false } }
Result:
Post? userPost; // <- result UserPost? userPost; // <- without forcing
-
Bugfix.
- Fixed JSON annotation key bug.
- Fixed JSON annotation key for Freezed and JSON serializable, ex:
@JsonKey(name: user_id)
. JSON key annotation will be added only when needed. This provides a cleaner code syntax. - Fixed a correction of plural class names.
- Added option to sort constructor declarations before other members.
- Fixed lint errors for empty classes.
- Documentation update.
- Fixed an issue with
Freezed
where optional dynamic keys were not allowed. - Fixed a bug with Dart Format.
- Improved implementation of code generation libraries to
pubspec.yaml
included and Freezed. All missing dependencies will be installed with one click. - Added file name enhancement. Separate your class name with a dot and after the dot everything will be added as enhancement name.
- Correction of certain descriptions.
- Added terminal focus when running the generator.
- Added actions from the right mouse button context menu.
- Improved setting quality.
- Added option to disable run build runner.
- Added button don't ask again for confirmation, when generating from the
models.json
file. - Bug fix.
- Removed Dart UI import for hashCode.
- To improve better stability and flexibility configuration from the file
models.jsonc
was moved to theSettings/Extensions/JSON To Dart Model
- Equality operator now sort lists first.
- Null-Safety enabled as default. To disable it go to the
Settings/Extensions/JSON To Dart Model/Null Safety
-
Expression body for
fromJson
andtoJson
. In most cases it has a nicer format. -
More
DateTime
format support.// Supported date formats. 2008-09-15T15:53:00 2007-03-01T13:00:00Z 2015-10-05T21:46:54-1500 2015-10-05T21:46:54+07:00 2020-02-06T14:00:00+00:00
-
Bugfix for merging class definitions.
-
More accurate marking of null safety indication.
-
Bugfix for annotation marking.
- see pull request from Arnas
- Improved equality operator.
- Added annotations support.
It is possible to mark JSON
values as default or required by adding to your JSON
key d@
or r@
- see pull request from Arnas
- Improved some syntax correction.
- see pull request from Arnas
- Added primary configuration option to the
models.jsonc
file. - Those who update to 3.1.0 from older version. Be sure to add
"primaryConfiguration": false
tomodels.jsonc
configuration or go to help for more information if you were warned.
- Added primary configuration option to the
-
see pull request from Arnas
- Added support for Dart null safety.
For any suggestions on how to improve the better null safety syntax your are welcome to open discuss.
- Those who update to 3.1.0 from older version. Be sure to add
"nullSafety": false,
tomodels.jsonc
configuration or go to help for more information if you were warned.
- see pull request from Arnas
- Added better support for building models from
models.jsonc
file. - Those who update to 3.0.2 from older version. Be sure to add
"fastMode": false
tomodels.jsonc
configuration or go to help for more information if you were warned.
- Added better support for building models from
- see pull request from Arnas
- Added support to build from file.
- see pull request from Arnas
- Added support for duplicate structures.
- see pull request from Arnas
- Added return as a received keyword
- see pull request from Arnas
- Added responsive formatting and date support.
- see pull request from Arnas
- Added better support for deeply nested json objects.
- Added support for list of lists. (Hot fix)
- nested array not generating properly - pull request from Ayush P Gupta
- Use original case of json fields - pull request from Ayush P Gupta
- see pull request from Arnas
copyWith()
method- Equality Operator
- support array of arrays
- Freezed support
- see pull request from Arnas
- Fixed List to List
- improved with Effective Dart: Style
- removed unwanted
new
keywords
- Fixed temporary windows folder selection issue
- Files stop generating when some dart file is duplicated
- Field names are bad formatted in the equatable related
props
override - Cannot read type of undefined
- Fixed JsonSerializable.toJson
- Also appends --delete-conflicting-outputs to the flutter pub run build_runner build command in the terminal so it can always be built
- Adds the ability to have better equality checks in the generated Dart models using the Equatable package.
- fixed filename, snake cased file create error when underscore.
@JsonKey
annotation to code generation library generated codes. Read more about Creating model classes the json_serializable way
- fixed extra empty lines on import section mistake
- chagelogs version mistake
- Added command to generate model classes according to code generation libraries.
- generate models with selected json.
- generate models with copied json.
- add terminal session to run build command
flutter pub run build_runner build
. Read more about Serializing JSON using code generation libraries.
- Code generation packages appending command. read more about Serializing JSON using code generation libraries.
- fixed numbers exponent error.
- downgraded support version of vs code from 1.3 to 1.2
- fixed array sub type error when subtype is not a primitive.
- fixed array sub type import error when subtype is not a primitive.
- fixed array subtype class generate error.
- fixed error when null values appear.
- display errors added.
- icon changed
- Json convert to dart models