Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/thien-do/int-be
Fake back end for InterNations' Front End challenge
https://github.com/thien-do/int-be
Last synced: 6 days ago
JSON representation
Fake back end for InterNations' Front End challenge
- Host: GitHub
- URL: https://github.com/thien-do/int-be
- Owner: thien-do
- Created: 2019-08-12T15:19:04.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-12-11T01:42:08.000Z (about 2 years ago)
- Last Synced: 2024-10-31T00:22:51.628Z (about 2 months ago)
- Language: JavaScript
- Homepage: https://int-be.herokuapp.com/
- Size: 171 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Overview
This is a mock back end for [InterNations' Front End challenge](https://github.com/dvkndn/int-fe/blob/master/TASK.pdf). It uses [JSON Server](https://github.com/typicode/json-server) and deployed to https://int-be.herokuapp.com/. To run it locally:
```bash
npm start
```For the front-end counterpart, please see http://github.com/dvkndn/int-fe.
## Models
For the challenge, the mock back end serves 2 simple models:
```ts
interface Group {
id: string;
name: string;
/* ... */
}interface User {
id: string;
email: string;
/* ... */
}
```For detailed structures and implementations, please see [db.js](db.js).
To represent the concept that a user may belong to several groups, and a group may have several users, the back end also implemented a simple many-to-many model:
```ts
interface Link {
id: string;
groupId: string;
userId: string;
}
```Thanks to the versatility of JSON Server, the 3 models should be enough to server most, if not all, cases of the challenge.