https://github.com/codenoble/active_model_normalizr
An ActiveModelSerializers adapter for Normalizr-like JSON
https://github.com/codenoble/active_model_normalizr
flux gem json rails redux ruby ruby-gem serializer
Last synced: 2 months ago
JSON representation
An ActiveModelSerializers adapter for Normalizr-like JSON
- Host: GitHub
- URL: https://github.com/codenoble/active_model_normalizr
- Owner: codenoble
- License: mit
- Created: 2017-02-01T02:00:05.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-02-01T02:01:02.000Z (over 9 years ago)
- Last Synced: 2025-10-06T20:15:35.632Z (9 months ago)
- Topics: flux, gem, json, rails, redux, ruby, ruby-gem, serializer
- Language: Ruby
- Size: 11.7 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: MIT-LICENSE
Awesome Lists containing this project
README
Active Model Normalizr
======================
[Normalizr](https://github.com/paularmstrong/normalizr)-like serialization for [Active Model Serializers](https://github.com/rails-api/active_model_serializers).
Active Model Normalizr provides a custom [adapter](https://github.com/rails-api/active_model_serializers/blob/master/docs/general/adapters.md) for Active Model Serializers. So you can write your serializers like you always have and the output will be in a normalizr-like format that's easy to use with [Redux](http://redux.js.org/) or [Flux](https://facebook.github.io/flux/).
Installation
------------
Add it to your `Gemfile`
```ruby
gem 'active_model_normalizr'
```
In a Rails initializer or somewhere similar:
```ruby
ActiveModelSerializers.config.adapter = ActiveModelSerializers::Adapter::Normalizr
```
Supported Dependency Versions
=============================
- `active_model_serializers ~> 0.10`