model_code_generator 1.0.1 copy "model_code_generator: ^1.0.1" to clipboard
model_code_generator: ^1.0.1 copied to clipboard

Model Code Generator is a simple command for make a model in flutter. it's very easy to use.

Model Code Generator for Flutter #

Model Code Generator is a simple command for make a model in flutter. it's very easy to use.

What It does? #

  • ✅ Create a model file based on your json.
  • ✅ Include fromJson and toJson function.
  • ✅ No internet connection needed.

How to Use? #

Add Model Code Generator to your pubspec.yaml in dev_dependencies: section.

dev_dependencies:
  model_code_generator: ^1.0.1

Update dependencies

flutter pub get

Run this command to create model file.

flutter pub run model_code_generator <yourclassname>

Where <yourclassname> is the class and file name that you want for your model. replace it with any name you want.

Example:

flutter pub run model_code_generator user

Then input/paste the json. Example JSON:

{
  "name" : "John Doe",
  "Age" : 25,
  "isHandsome" : true
}

Press Enter twice to finish.

Contact #

3
likes
140
points
15
downloads

Publisher

unverified uploader

Weekly Downloads

Model Code Generator is a simple command for make a model in flutter. it's very easy to use.

Homepage
Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on model_code_generator