Door Dash onsight frontend interview

Education: Bachelors in Computer Science Years of Experience (YOE): 6

Questions Asked:

The 60-minute interview on CoderPad with a Senior Engineer focused on UI implementation.

  1. UI Coding Challenge: Build a simple image carousel component.
  • I was asked to implement a basic, functional image carousel.
  • Requirements included: Next/Previous buttons, a visual indicator for the current slide (e.g., dots), and infinite looping.
  • I used React to build the component, managing the current slide index in component state.
  • Follow-up questions:
    • “How would you add auto-play functionality?”
    • “Discuss accessibility considerations for this component (e.g., ARIA attributes, keyboard navigation).”
    • “How would you optimize performance if there were a large number of high-resolution images?”
  1. CSS/Styling Discussion:
  • “Given a responsive design, how would you ensure the carousel images maintain a consistent aspect ratio across different screen sizes without distortion?”
  • I discussed using object-fit: cover or object-fit: contain for images within a container, and flexible box models (e.g., flexbox or grid) for layout, potentially using aspect ratio hacks with padding-bottom for older browsers or specific use cases.

The interviewer was keen on understanding my thought process for breaking down the UI into manageable parts and considering edge cases in both functionality and styling.