{"id":27598135,"url":"https://github.com/flippakitten/frap","last_synced_at":"2025-04-22T14:12:22.338Z","repository":{"id":48146750,"uuid":"197360173","full_name":"flippakitten/frap","owner":"flippakitten","description":"CLI to create a Flutter App backed with a Rails server for quick app protoyping","archived":false,"fork":false,"pushed_at":"2023-01-19T14:22:38.000Z","size":2406,"stargazers_count":21,"open_issues_count":13,"forks_count":1,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-19T23:48:04.603Z","etag":null,"topics":["cli","flutter","frap","gem","rails"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/flippakitten.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":null,"patreon":"flippakitten","open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2019-07-17T09:38:39.000Z","updated_at":"2024-10-14T08:56:44.000Z","dependencies_parsed_at":"2023-02-11T03:30:56.038Z","dependency_job_id":null,"html_url":"https://github.com/flippakitten/frap","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flippakitten%2Ffrap","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flippakitten%2Ffrap/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flippakitten%2Ffrap/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flippakitten%2Ffrap/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/flippakitten","download_url":"https://codeload.github.com/flippakitten/frap/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249898695,"owners_count":21342408,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","flutter","frap","gem","rails"],"created_at":"2025-04-22T14:12:21.496Z","updated_at":"2025-04-22T14:12:22.319Z","avatar_url":"https://github.com/flippakitten.png","language":"Ruby","funding_links":["https://patreon.com/flippakitten"],"categories":[],"sub_categories":[],"readme":"[![Build Status](https://travis-ci.com/flippakitten/frap.svg?branch=master)](https://travis-ci.com/flippakitten/frap)\n[![Gem Version](https://badge.fury.io/rb/frap.svg)](https://badge.fury.io/rb/frap) \n[![Join the chat at https://gitter.im/frap-flutter-rails-cli/community](https://badges.gitter.im/frap-flutter-rails-cli/community.svg)](https://gitter.im/frap-flutter-rails-cli/community?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge\u0026utm_content=badge)\n[![Maintainability](https://api.codeclimate.com/v1/badges/4a8f6e079b127cdb0b79/maintainability)](https://codeclimate.com/github/flippakitten/frap/maintainability)\n# Frap \nCLI interface to quickly prototype Flutter App's using the BLoC pattern with a Rails API server.  \n\n[changelog](https://github.com/flippakitten/frap/wiki/Change-Log-Published)  \n[roadmap](https://github.com/flippakitten/frap/projects/2)  \n\n## Prerequisites\n\nEnsure the following are installed:\n* [Flutter](https://flutter.dev/docs/get-started/install)\n* [Ruby 2.6.5](https://rvm.io/rvm/install) (I've used RVM but you can install it anyway)\n* Rails 6.0.1\n\n## Installation\n\nInstall:\n\n    $ gem install frap\n\n## Usage\n\nCheck the version  \n`frap --version`\n\nCreate a new Flutter and Rails app.  \n`frap new my_app`  \nThis will create a new Parent directory for the Rails and Flutter App.  \n```\n|__ my_app  \n  |__ my_app_server  \n  |__ my_app_ui\n```\nGenerate a Rails and Flutter Resource from the app route directory `/my_app`, **currently does NOT support references, please open an ISSUE for broken data types**  \n`frap generate resource post -a title:string body:text`  \n\nThe next step is to implement your Rails controller method for index action and run the migrations:\n```\ncd my_app/my_app_server\nrails db:migrate\n```\nYou can then edit the `app/constrollers/posts_controller.rb`:\n```ruby\nclass PostsController \u003c ApplicationController\n  def index\n    render json: { posts: Post.all.as_json }, status: :ok\n  end\nend\n```\nNext fire up Rails and Flutter (you may need to start up an emulator, just follow the terminal output:\n```bash\ncd my_app/my_app_server\nrails s\n\ncd my_app/my_app_ui\nflutter run\n```\n\n\n## Motivation\nMoving from the old school PHP/HTML/JS/jQuery/Yii(later came bootstrap) into the Rails way of life, I quickly fell in love with Rails and how easy it was to build basic functionality.  \n\nIn stepped in NodeJS and React and I was back to having to build everything from scratch, mixing presentation logic and business logic together \"because it's the same thing\" and then extracting components because as it turns out, it's not the same thing... **Not good for productivity** and it's very expensive, especially for startups.  \n\nSince then I've been trying every new JS framework and nothing really made things less convoluted.  \n\nWhen I started looking into Flutter and the recommended way to manage state using the BLoC pattern, I realized that the BLoC pattern and the way Flutter apps are structured (everythings a Widget much like everything is an Object) lends itself code automation, getting the boilerplate out the way.\n\nThe goal this CLI is to mimic Rails generators and allow you to do something like:\n`frap g resource User name:string,email:string,age:int,password_digest`\nThis will call the rails generator as one would expect. In addition, it will create the \"view\", or page in Flutter with all the fields, routes and blocs ready to use, ready to save and most importantly... Already styled using the material dart package.\n\n## Development\n\nAfter checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.\n\nTo install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/flippakitten/frap. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.\n\n## License\n\nThe gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).\n\n## Code of Conduct\n\nEveryone interacting in the Frap project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/flippakitten/frap/blob/master/CODE_OF_CONDUCT.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflippakitten%2Ffrap","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflippakitten%2Ffrap","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflippakitten%2Ffrap/lists"}