I'm a Rails beginner and currently attempting to make a web application where a user may be shown an array of cards and is able to swipe each card either left or right. I found Gajus/Swing which gave me a great-looking swipeable cards interface in its example "card-stack".
Now, while I'm able to run a rails server with the functional interface (I can drag cards from the stack), I have no clue how to keep record of which card was swiped to which direction in the backend (Rails/ActiveRecord). How does the backend work when integrating this JavaScript interface with Rails?
Please ask me to clarify anything if needed. Any help is appreciated
PS: I'm asking here because I figure this is more a general question about JavaScript+Rails than the one about the Swing interface itself.