a rails4 stack with an api and frontend javascript client