How do you convert a Rails 5 API app to a rails app that can act as both API and app?

前端 未结 3 809
情歌与酒
情歌与酒 2020-12-29 06:03

I initially created it in rails 5 with the --api tag.

From http://edgeguides.rubyonrails.org/api_app.html,

I removed config.api_only = true

3条回答
  •  礼貌的吻别
    2020-12-29 06:13

    From a directory outside of the api application (such as its parent - cd ..) I would do

    rails new comparison_real_app
    

    and then compare the contents of the comparison_real_app with your app and copy over the files that are missing into the api app and change any other files as required.

提交回复
热议问题