iOS Coding Challenge - aacml/Recruiting GitHub Wiki

The Task

Build a simple iOS application that features:

  1. A Web View: On launch, the app should load https://www.bonprix.de/ in a web view.

  2. Navigation Menu:

    • Implement a navigation bar button that opens a full-screen modal view.

    • This modal view will display a hierarchical menu structure, navigable using a navigation stack.

    • The menu data is retrieved from a REST API at https://codechallenge.mobilelab.io/v1/bonprix/navigation using the provided API key (N8Nx0OwOvo1iuN2ZkFHZlyVKBVgoIcy4tUHMppO5 in the x-api-key request header).

    • Here is an example response:

      {
        "categories": [
          {
            "label": "Shop",
            "url": "https://www.bonprix.de"
          },
          {
            "label": "Damen",
            "url": "https://www.bonprix.de/kategorie/damen/",
            "image": "https://image01.bonprix.de/bonprixbilder/teaser/app/channels/app-dez-19a.jpg",
            "children": [
              {
                "label": "Zur Übersicht",
                "url": "https://www.bonprix.de/kategorie/damen/"
              },
              {
                "label": "Mode",
                "url": "https://www.bonprix.de/kategorie/damen-mode/",
                "children": [
                  {
                    "label": "Alle Artikel anzeigen",
                    "url": "https://www.bonprix.de/kategorie/damen-mode/"
                  },
                  {
                    "label": "Neuheiten",
                    "url": "https://www.bonprix.de/kategorie/damen-neu/",
                    "children": [
                      {
                        "label": "Alle Artikel anzeigen",
                        "url": "https://www.bonprix.de/kategorie/damen-neu/"
                      },
                      {
                        "label": "Oberteile",
                        "url": "https://www.bonprix.de/kategorie/damen-alle-neuen-artikel-oberteile/"
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ]
      }
      
  3. Menu Interaction:

    • Selecting a menu entry should close the modal view and load the corresponding URL in the main web view.

Visual Reference:

Refer to this animation for a better understanding of the expected functionality (ignore the tab bar or product specific theming):

Data Handling:

Parse the JSON response from the API and create appropriate data models in Swift.

Optional: Teaser Images

Top-level menu nodes may have an image URL. If available, display this as a teaser image.

Requirements

  • Xcode 15.x
  • Swift 5.x
  • Use SwiftUI as UI framework, do not use UIKit
  • Minimum OS target version: iOS 15
  • Testing: Include unit and/or UI tests
  • Use a (local) Git repository for version control.
  • Submission:
    • Provide a written summary of your development process and decisions.
    • Share your project via a Git repository link or ZIP archive.

Additional Information

Hints:

  • Focus on core functionality over elaborate styling. No need for custom colours or fonts. Use SF Symbols if you need icon art.
  • Implement basic error handling.
  • Minimize reliance on third-party libraries.

Timeline:

  • This challenge should take a few hours to complete. Note any shortcuts taken in your project summary.

Questions? Feel free to emails us.

We look forward to seeing your solution!