The purpose of this assessment is to demonstrate:
- An understanding of React syntax
- Working with an API
- Storing and manipulating React state
- Structuring an application with multiple components
- HTML and CSS ability
- Responsive web development ability
In order to run the provided solution the following software will need to be installed:
- Fork and clone the repository
- Open the repository folder and install the dependencies using
yarn
ornpm install
. - Run the development server using
yarn start
ornpm start
.
The repository contains a App.jsx
file inside the components
folder; this should be the starting point for your exercise. Please feel free to create more components to structure your app in a logical manner.
The repository also contains an API endpoint mocked using MirageJS. This can be accessed when running the development server at the URL /api/posts
.
We would love to see code comments to help explain your approach and thought process, this will also be discussed in a follow-up technical interview.
Finally, the use of third party libraries and/or components is permitted - and in some cases encouraged. However, please ensure that you are still demonstrating the skills we have outlined above.
These are the minimum requirements for the exercies:
- Retrieve the data from the mock API.
- Output the data in a list, including properties from the data that are appropriate for a list view.
- Implement a category filter - this can be single or multi-select.
- Implement pagination - this can be traditional numbered pages or "load more".
- Use semantic markup where possible.
- Create a responsive layout with HTML and CSS.
If you have time then demonstrating any of the following would be considered as a bonus:
- Use client-side routing to create a "detail" page.
- Persist filter state in the query string.
- Include animated transitions between application state, e.g. when filtering.
- Convert the application to use TypeScript instead of JavaScript.
- Use a CSS preprocessor or CSS-in-JS rather than plain CSS.
Please submit your completed exercise either by supplying the URL of your forked repository - please ensure you do not include the node_modules
folder.