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

A command-line tool for GetX to automate module creation.

flutter_getx_cli #

A command-line tool to speed up your GetX development workflow in Flutter.

Installation #

dart pub global activate flutter_getx_cli

Usage #

Create a new module #

flutter_getx_cli create <module_path>

This will create a new module with a view, controller, and binding. It will also automatically inject the route into your app_pages.dart and app_routes.dart files.

Example:

flutter_getx_cli create auth/login

Generated Folder Structure #

The command above will generate the following folder structure:

lib
└── app
    ├── modules
    │   └── auth
    │       └── login
    │           ├── bindings
    │           │   └── login_binding.dart
    │           ├── controllers
    │           │   └── login_controller.dart
    │           └── views
    │               └── login_view.dart
    └── routes
        ├── app_pages.dart
        └── app_routes.dart

It will also add a new route to lib/app/routes/app_routes.dart and a new GetPage to lib/app/routes/app_pages.dart.

Options:

  • --no-route: Create the module without adding a route.

Remove a module #

flutter_getx_cli remove <module_path>

This will remove the module directory and its associated routes.

Options:

  • --routes-only: Only remove the routes, leaving the module files intact.
1
likes
0
points
37
downloads

Publisher

unverified uploader

Weekly Downloads

A command-line tool for GetX to automate module creation.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

path

More

Packages that depend on flutter_getx_cli