Skip to content

Paradxil/coding-challenge

Repository files navigation

CodingChallenge

This repo features a small monorepo setup using NX, NextJS, and NestJS.

The goal of this challenge is to add a new feature to an existing codebase, using technologies you may or may not be familiar with.

About

A common requirement we often face as developers is to load data from an api and display it in some way for our end users.

This repo uses the public census.gov api endpoints to load economic data from the 2022 census, and display a few statistics.

This challenge will ask you to add an additional endpoint to the NestJS server and render it in the NextJS ui.

Services

There are two main services in the apps folder, a ui app for displaying employment census data, and a server for fetching data from the public census.gov apis.

Libraries

In addition to the services in the apps folder, there is one shared library in the libs folder called types.

As the name suggests this library exports typescript types for shared use between the ui and server apps.

Development

You may not be familiar with NX. NX is a monorepo tool that simplifies local dependency management and has tools for running apps inside the monorepo.

To start run npm i as usual to install dependencies.

Instead of using traditional npm run dev commands, you may start both services using the following command:

npx nx --no-tui run-many -t dev

Then visit localhost:3000 to view the ui. The server is running at localhost:3010/api.

If you prefer, NX provides a TUI. To enable the TUI run the following command:

npx nx run-many -t dev

You may run a single service as follows:

npx nx run server:dev

or

npx nx run ui:dev.

The Challenge

Your challenge is as follow:

Our app users are excited to have a new dashboard for viewing the latest economic census data. Although the single existing datapoint shown (total number of employees in a given industry) is useful, users would also like to see number of employees per state.

Please add additional ui to the dashboard to display the number of employees, for a given industry, broken down by state.

You may structure this ui however you like.

You will need to add additional capabilities to the server to fetch this data from the census.gov website.

Resources:

Terms:

  • NAICS: I've largely replaced this term in the codebase with the word industry or industryCode. It stands for "North American Industry Classification System".

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors