Instead of to_xml and as_json, simply implement to_api. Return an unformatted hash. Let the model understand the data. Let the controller understand the format. In Rails, the controller can simply call render :xml => model.to_api or render :json => model.to_api.
☆16Jan 20, 2017Updated 9 years ago
Alternatives and similar repositories for to_api
Users that are interested in to_api are comparing it to the libraries listed below. We may earn a commission when you buy through links labeled 'Ad' on this page.
Sorting:
- Wrapping Objection in RubyMotion.☆25Jan 14, 2015Updated 11 years ago
- An action RPG created in Ruby☆22May 3, 2013Updated 13 years ago
- A small Objective-C wrapper around GCD☆30Sep 24, 2012Updated 13 years ago
- A collection of strategies for Warden☆19Mar 1, 2010Updated 16 years ago
- Jumprope-based local content store☆55Mar 17, 2013Updated 13 years ago
- Managed hosting for WordPress and PHP on Cloudways • AdManaged hosting for WordPress, Magento, Laravel, or PHP apps, on multiple cloud providers. Deploy in minutes on Cloudways by DigitalOcean.
- Nice-FFI: Convenience layer atop Ruby-FFI☆23Jul 8, 2015Updated 11 years ago
- ☆10Nov 25, 2022Updated 3 years ago
- Palmist☆17May 13, 2008Updated 18 years ago
- Little Fortune Planet LD38 Jam entry☆10May 20, 2017Updated 9 years ago
- Write Ruby extensions with Crystal☆12Jan 18, 2016Updated 10 years ago
- Ludum Dare 38 Jam submission☆10Oct 24, 2022Updated 3 years ago
- MOVED TO https://github.com/pry/pry-stack_explorer☆18Nov 29, 2015Updated 10 years ago
- Simple Ruby trees☆18Apr 14, 2010Updated 16 years ago
- A CLI app for getting the weather forecast using forecast.io's API.☆15Apr 21, 2015Updated 11 years ago
- Managed Kubernetes at scale on DigitalOcean • AdDigitalOcean Kubernetes includes the control plane, bandwidth allowance, container registry, automatic updates, and more for free.
- particle attractor, multiverse, ruby game programming tutorial & 2d engine☆15Jul 6, 2009Updated 17 years ago
- Calculations around the National Retail Federation's 4-5-4 calendar☆14Updated this week
- Hamcrest - library of matchers for building test expressions - for Objective-C.☆25Sep 8, 2011Updated 14 years ago
- Ruby wrapper for the CheddarGetter API☆27Jan 11, 2011Updated 15 years ago
- Multiplayer same-screen action shooter.☆15Oct 19, 2022Updated 3 years ago
- Ruby gem to generate excerpts from html formatted text. Great for blogs.☆28Jan 28, 2020Updated 6 years ago
- A Ruby gem for streaming remote files one line at a time☆12Jul 13, 2026Updated last week
- Snelps is a RTS written in Rubygame☆15May 31, 2012Updated 14 years ago
- An ActiveRecord database adapter that allows you to setup a "master/slave" environment☆99Nov 9, 2009Updated 16 years ago
- AI Agents on DigitalOcean Gradient AI Platform • AdBuild production-ready AI agents using customizable tools or access multiple LLMs through a single endpoint. Create custom knowledge bases or connect external data.
- A Rails plugin to track database queries.☆37Dec 1, 2008Updated 17 years ago
- ☆13Aug 4, 2016Updated 9 years ago
- A* pathfinding in Ruby☆19Mar 20, 2013Updated 13 years ago
- Explore Ruby Audio through examples using libraries from various authors☆15Jan 4, 2010Updated 16 years ago
- A game made entirely in Ruby. They said it couldn't be done, so I did it anyway :)☆16Nov 25, 2017Updated 8 years ago
- Ruby-FFI binding to SDL multimedia libraries. (Still in alpha)☆16Mar 6, 2011Updated 15 years ago
- RTS game engine for Atomic Games☆24Nov 9, 2024Updated last year
- Updated build/specs for ruby-1.9.3☆15Jan 18, 2012Updated 14 years ago
- rendering views via HTML::Pipeline in Rails☆20Aug 14, 2017Updated 8 years ago
- Deploy open-source AI quickly and easily - Special Bonus Offer • AdRunpod Hub is built for open source. One-click deployment and autoscaling endpoints without provisioning your own infrastructure.
- This Rails plugin/gem allows you to generate virtual boolean attributes, which get saved in the database as a single bitset integer.☆23Feb 6, 2011Updated 15 years ago
- Ruby client for the Posterous API☆23May 4, 2016Updated 10 years ago
- Developer-Friendly, In-Browser Presentation Software with auto-resize and syntax highlighting☆17Oct 25, 2014Updated 11 years ago
- A music synthesizer written in Ruby☆19Sep 10, 2008Updated 17 years ago
- Small ruby code snippets for Raspberry Pi peripherals from Adafruit☆16Jul 27, 2015Updated 10 years ago
- A small utility to get the colors of an image.☆15Apr 15, 2011Updated 15 years ago
- Currently just a growing skeleton for roguelike game being written in ruby (NCurses interface) and tested with RSpec☆16Dec 15, 2008Updated 17 years ago