Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed .DS_Store
Binary file not shown.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@
!/tmp/.keep

.byebug_history

.DS_Store
1 change: 1 addition & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ git_source(:github) do |repo_name|
"https://github.com/#{repo_name}.git"
end

gem 'active_model_serializers'

# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 5.1.4'
Expand Down
9 changes: 9 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ GEM
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.0.3)
active_model_serializers (0.10.6)
actionpack (>= 4.1, < 6)
activemodel (>= 4.1, < 6)
case_transform (>= 0.2)
jsonapi-renderer (>= 0.1.1.beta1, < 0.2)
activejob (5.1.4)
activesupport (= 5.1.4)
globalid (>= 0.3.6)
Expand Down Expand Up @@ -52,6 +57,8 @@ GEM
debug_inspector (>= 0.0.1)
builder (3.2.3)
byebug (9.1.0)
case_transform (0.2)
activesupport
coderay (1.1.2)
concurrent-ruby (1.0.5)
crass (1.0.2)
Expand All @@ -70,6 +77,7 @@ GEM
jquery-turbolinks (2.1.0)
railties (>= 3.1.0)
turbolinks
jsonapi-renderer (0.1.3)
listen (3.1.5)
rb-fsevent (~> 0.9, >= 0.9.4)
rb-inotify (~> 0.9, >= 0.9.7)
Expand Down Expand Up @@ -165,6 +173,7 @@ PLATFORMS
ruby

DEPENDENCIES
active_model_serializers
better_errors
binding_of_caller
byebug
Expand Down
3 changes: 3 additions & 0 deletions app/serializers/movie_serializer.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
class MovieSerializer < ActiveModel::Serializer
attributes :title, :overview, :release_date, :inventory
end