Skip to content

ypk/rightmove-techtest

This branch is up to date with rightmove/remote-front-end-test:master.

Folders and files

NameName
Last commit message
Last commit date
Jul 20, 2022
Jul 28, 2022
Jul 21, 2022
Jul 21, 2022
Aug 11, 2020
Jul 20, 2022
Jul 20, 2022
Oct 19, 2023
Jul 20, 2022
Jul 20, 2022
Jul 20, 2022
Oct 19, 2023
Oct 19, 2023
Jul 21, 2022

Repository files navigation

FED Test

Instructions

This test requires Node.js version v20 or higher to be installed.

Install required dependencies by running npm ci. Then start the project by running npm start. The start script will start both the api server and the react app (in the development mode) in parallel. npm test launches the test runner in the interactive watch mode.

Frontend

The frontend is accessible at http://localhost:5173/.

API

The api is accessible at http://localhost:3000/api and provides the following endpoints.

GET /properties

Returns all properties as a list, which looks like:

[
    {
        "id": 73864112,
        "bedrooms": 3,
        "summary": "Situated moments from the River Thames in Old Chelsea...",
        "displayAddress": "CHEYNE WALK, CHELSEA, SW3",
        "propertyType": "Flat",
        "price": 1950000,
        "branchName": "M2 Property, London",
        "propertyUrl": "/property-for-sale/property-73864112.html",
        "contactUrl": "/property-for-sale/contactBranch.html?propertyId=73864112",
        "propertyTitle": "3 bedroom flat for sale",
        "mainImage": "https://media.rightmove.co.uk/dir/crop/10:9-16:9/38k/37655/53588679/37655_CAM170036_IMG_01_0000_max_476x317.jpg"
    },
    {
        ...
    }
]

Filter and sort the result set

In order to filter and sort the result, please the supply relevant query parameters. (e.g. http://localhost:3000/api/properties?maxPrice=800000)

parameter description
propertyTypes Comma separated list of property types to include in your result set
(e.g. detached, semi-detached, terraced, flat, apartment, maisonette, mews, boat)
minPrice The minimum property price
(e.g. 400000)
maxPrice The maximum property price
(e.g. 700000)
minBeds The minimum number of bedrooms
(e.g. 3)
maxBeds The maximum number of bedrooms
(e.g. 5)
sortBy Sort the result by property price or the number of bedrooms
(e.g. price, bedrooms)
orderBy Order the result in either ascending or descending order
(e.g. asc, desc)

NOTE Supplying invalid query parameter (empty, null or undefined) will return an empty list. Please omit query parameters without any value.

About

Technical test for RightMove

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 76.2%
  • SCSS 15.4%
  • HTML 8.4%