0

I am a chef and I am making a cook book app that has all my recipes in it. The app has a table view with many cells that have the name of the recipes. Once the cell is tapped, It should go into a detailed view where the recipe is displayed. However, every recipe is different, and I cannot have the same layout for all my recipes. I want to be able to customize every recipe like putting in image and changing the font in some text editor and then import them to my app.

  • How can I do it?
  • What should I use?
  • And how to store the data?
Nikolay Fominyh
  • 8,946
  • 8
  • 66
  • 102
Jerry Xu
  • 295
  • 2
  • 19

1 Answers1

1

The best idea is to create JSON model for every recipes. JSON will be describe recipe layout. Then implement some kind of parser which can understand information in JSON to create view layout via code.

So you need a JSON with list of recipes and set of JSONs for every recipe. Your app create list of recipes from list JSON and after select get information which recipe`s JSON should use.

You can store this JSON on server, for example Firebase (free for small data) or keep on device hard-coded.

The others idea:

  1. Create pdf file for every recipes and load this files into app. Example
  2. Create html layout and load it into UIWebView.
Community
  • 1
  • 1
Kamil Harasimowicz
  • 4,684
  • 5
  • 32
  • 58