{"id":13394993,"url":"https://github.com/thoughtbot/flutie","last_synced_at":"2025-05-15T02:08:21.181Z","repository":{"id":619037,"uuid":"258137","full_name":"thoughtbot/flutie","owner":"thoughtbot","description":"View helpers for Rails applications","archived":false,"fork":false,"pushed_at":"2023-03-08T19:46:41.000Z","size":379,"stargazers_count":729,"open_issues_count":10,"forks_count":41,"subscribers_count":38,"default_branch":"main","last_synced_at":"2025-04-14T00:57:43.025Z","etag":null,"topics":[],"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/thoughtbot.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2009-07-22T21:18:28.000Z","updated_at":"2025-02-23T12:24:03.000Z","dependencies_parsed_at":"2023-07-05T15:02:50.976Z","dependency_job_id":null,"html_url":"https://github.com/thoughtbot/flutie","commit_stats":{"total_commits":389,"total_committers":28,"mean_commits":"13.892857142857142","dds":"0.33676092544987146","last_synced_commit":"f3f8043c70358b43cdf9f156770286cb56e3483c"},"previous_names":[],"tags_count":28,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thoughtbot%2Fflutie","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thoughtbot%2Fflutie/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thoughtbot%2Fflutie/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thoughtbot%2Fflutie/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thoughtbot","download_url":"https://codeload.github.com/thoughtbot/flutie/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254259384,"owners_count":22040820,"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":[],"created_at":"2024-07-30T17:01:38.543Z","updated_at":"2025-05-15T02:08:21.139Z","avatar_url":"https://github.com/thoughtbot.png","language":"Ruby","readme":"# Flutie\n\n[![Build Status](https://travis-ci.org/thoughtbot/flutie.svg?branch=master)](https://travis-ci.org/thoughtbot/flutie)\n\nFlutie provides some utility view helpers for use with Rails applications.\n\nThere are helpers for setting a page title and for generating body classes.\n\n## Installation \u0026 Upgrading\n\nFlutie is a Railtie. We support the versions of Ruby and Rails listed in\n[.travis.yml](.travis.yml).\n\nIt should be run as a gem and included in your `Gemfile`:\n\n```ruby\ngem \"flutie\"\n```\n\n## Helpers\n\nFlutie provides helper methods for use within Rails layouts and views.\n\n### Page Title\n\nThe `page_title` method can be used like:\n\n```erb\n\u003ctitle\u003e\u003c%= page_title %\u003e\u003c/title\u003e\n```\n\nBy default, it will produce results like:\n\n```html\n\u003ctitle\u003eAppname : page title\u003c/title\u003e\n```\n\n* \"App name\" comes from the module name of the rails application created by your\n  app, i.e. `Appname::Application` will produce \"Appname\"\n* \"page\" comes from trying `content_for(:page_title)` and assumes you are using\n  `content_for` with `:page_title` symbol on your pages.\n* The separator defaults to \" : \"\n\nThese can be overridden by passing an options hash including `:app_name`,\n`:page_title_symbol` and `:separator` hash keys. For example:\n\n```ruby\ncontent_for(:site_page_title, 'My title of my page')\npage_title(:app_name =\u003e 'My app name', :page_title_symbol =\u003e :site_page_title, :separator =\u003e \" | \")\n```\n\nwould produce:\n\n```html\n\u003ctitle\u003eMy app name | My title of my page\u003c/title\u003e\n```\n\nYou can also reverse the position of the `:app_name` and the `:site_page_title`\nvalues by using the `:reverse` option. For example:\n\n```ruby\ncontent_for(:site_page_title, 'My title of my page')\npage_title(:app_name =\u003e 'My app name', :page_title_symbol =\u003e :site_page_title, reverse: true)\n```\n\nwould produce:\n\n```html\n\u003ctitle\u003eMy title of my page : My app name\u003c/title\u003e\n```\n\n### Body Class\n\nThe `body_class` method can be used like this in a layout:\n\n```erb\n\u003cbody class=\"\u003c%= body_class %\u003e\"\u003e\n```\n\nThis will produce a string including the controller name and controller-action\nname pair.  For example, The `WidgetsController#show` action would produce:\n\n```html\n\u003cbody class=\"widgets widgets-show\"\u003e\n```\n\nAnything which has been added via `content_for(:extra_body_classes)` will be\nadded to the end, for example views like:\n\n```erb\ncontent_for(:extra_body_classes, 'special-page')\n\u003cbody class=\"\u003c%= body_class %\u003e\"\u003e\n```\n\nwould produce:\n\n```html\n\u003cbody class=\"widgets widgets-show special-page\"\u003e\n```\n\n## How to contribute\n\nPlease see the [CONTRIBUTING](CONTRIBUTING.md) file for details.\n\n## Credits\n\n[![thoughtbot][thoughtbot-logo]][thoughtbot]\n\nFlutie is maintained and funded by [thoughtbot, inc][thoughtbot].\n\nThank you to all [the contributors]!\n\nThe names and logos for thoughtbot are trademarks of thoughtbot, inc.\n\n[thoughtbot]: https://thoughtbot.com?utm_source=github\n[thoughtbot-logo]: http://presskit.thoughtbot.com/images/thoughtbot-logo-for-readmes.svg\n\n## License\n\nFlutie is Copyright © 2010 thoughtbot, inc. It is free software, and may be\nredistributed under the terms specified in the [LICENSE](LICENSE) file.\n\n[the contributors]: https://github.com/thoughtbot/flutie/contributors\n","funding_links":[],"categories":["Ruby"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthoughtbot%2Fflutie","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthoughtbot%2Fflutie","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthoughtbot%2Fflutie/lists"}