17

如果我要使用 Ruby on Rails 框架来构建一个 Web 应用程序,那么我构建一个可以与 Web 应用程序对话和连接的移动应用程序(iOS/Android)的最佳途径是什么?

EG:twitter.com (DESKTOP) - twitter iOS 或 Android 应用程序。

4

2 回答 2

23

这将需要大量阅读。

您将需要在 Rails 框架上构建 API 以与移动应用程序通信。以下是一些使用 Rails 创建 API 的好链接:

http://railscasts.com/episodes/350-rest-api-versioning http://collectiveidea.com/blog/archives/2013/06/13/building-awesome-rails-apis-part-1/

我建议使用 Devise 进行身份验证并使用他们的 authentication_token 来验证用户对您的 API 的网络请求。

http://matteomelani.wordpress.com/2011/10/17/authentication-for-mobile-devices/

这是我不久前收藏的一些有用的链接,以提供帮助。

http://pnhoang.tumblr.com/post/24160454924/build-a-rails-backend-api-for-an-iphone-client http://www.takeofflabs.com/posts/8-Rails-and-iOS -a-sample-starting-setup https://devcenter.heroku.com/articles/ios-photo-sharing-geo-location-service http://jessewolgamott.com/blog/2012/01/19/the-one -with-a-json-api-login-using-devise/

祝你好运

于 2013-11-07T20:30:47.970 回答
1

我知道这个问题是关于 Ruby on Rails 到 iOS/Andriod 的。你考虑过从 Ruby 到 iOS/Andriod 吗?看看RubyMotion。我认为使用 RubyMotion 将移动应用程序 iOS/Andriod 与 Ruby 应用程序连接起来比通过 Web 应用程序 ROR 更容易。

于 2015-09-19T07:27:58.270 回答