Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
e44541f
Project setup
iamdobbs Mar 4, 2023
e6a5e17
Peep Model Class created. First test for construct with empty peeps a…
iamdobbs Mar 4, 2023
1801ee1
Created #addPeep and #getPeeps. Tests passed for both functions.
iamdobbs Mar 4, 2023
43bfb23
Tests for adding multiple peeps created and passed
iamdobbs Mar 4, 2023
0c02428
index.js updated to console.log confirmation app is running
iamdobbs Mar 4, 2023
4710396
Refactored to use 'model' for const name
iamdobbs Mar 4, 2023
c8eb328
Minor changes to index.html to have header and main-container included
iamdobbs Mar 4, 2023
ada93ae
Minor refactor changes
iamdobbs Mar 4, 2023
bf5ad45
Main container added to file
iamdobbs Mar 4, 2023
825f7d4
Jest Install Files Updated
iamdobbs Mar 4, 2023
dd8d159
Jest Install Files Updated
iamdobbs Mar 4, 2023
ccff4f7
peepsView.js and test file created. #displayPeeps method written and …
iamdobbs Mar 4, 2023
ea49fca
peep-input added to index.html
iamdobbs Mar 5, 2023
36ad6f4
Updates to required files for manual testing
iamdobbs Mar 5, 2023
9ff50ec
Test created for adding peep with use of btn and eventlistener. Const…
iamdobbs Mar 5, 2023
068db7f
Test added to confirm displayPeeps was note repeating existing peeps …
iamdobbs Mar 5, 2023
6da6bbd
peepClient files created
iamdobbs Mar 5, 2023
bd7571b
jest-fetch-mock added to package files
iamdobbs Mar 5, 2023
371ea00
Test for fetch call and loading peeps. #loadPeeps created to pass test
iamdobbs Mar 5, 2023
5aeb9d0
Expanded on fetch/load test to include times called and beforeEach, r…
iamdobbs Mar 5, 2023
ceab7a0
Updated to include node-fetch
iamdobbs Mar 5, 2023
a0c5754
Created setPeeps function
iamdobbs Mar 5, 2023
ce48b68
Tests for fetch and display peeps from API. displayPeepsFromApi metho…
iamdobbs Mar 5, 2023
de30fbf
.catch for error added to loadPeeps function
iamdobbs Mar 5, 2023
1c19db7
displayError function created and tests written - passed
iamdobbs Mar 5, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
bundle.js
31 changes: 15 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
# Chitter API Frontend Challenge

* Feel free to use Google, your notes, books, etc. but work on your own
* If you refer to the solution of another coach or student, please put a link to that in your README
* If you have a partial solution, **still check in a partial solution**
* You must submit a pull request to this repo with your code by 9am Monday morning
- Feel free to use Google, your notes, books, etc. but work on your own
- If you refer to the solution of another coach or student, please put a link to that in your README
- If you have a partial solution, **still check in a partial solution**
- You must submit a pull request to this repo with your code by 9am Monday morning

Challenge:
-------
## Challenge:

As usual please start by forking this repo.

Expand All @@ -18,20 +17,20 @@ Your task is to build a front-end single-page-app to interface with this API. Yo

Here are some interactions the API supports. Implement as many as you see fit.

* Creating Users
* Logging in
* Posting Peeps
* Viewing all Peeps *(I suggest you start here)*
* Viewing individual Peeps
* Deleting Peeps
* Liking Peeps
* Unliking Peeps
- Creating Users
- Logging in
- Posting Peeps
- Viewing all Peeps _(I suggest you start here)_
- Viewing individual Peeps
- Deleting Peeps
- Liking Peeps
- Unliking Peeps

We are looking for well tested, easy to read, easy to change code. This is more important than the number of interactions you implement.

Note that others may be doing the same task at the same time, so the data may change as you are using it.

## Utilities you might find useful

* [The Fetch API](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch) for making requests.
* [Postman](https://www.getpostman.com/) or [Insomnia](https://insomnia.rest/) for exploring the API.
- [The Fetch API](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch) for making requests.
- [Postman](https://www.getpostman.com/) or [Insomnia](https://insomnia.rest/) for exploring the API.
22 changes: 22 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">

<title>My Chitter Challenge</title>
</head>
<body>
<h1>Chitter</h1>

<input type="text" id="peep-input" />
<button id="add-peep-btn">Add peep</button>

<div id="main-container">

</div>

<script type="text/javascript" src="bundle.js"></script>
</body>
</html>
5 changes: 5 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
const PeepsModel = require('./peepsModel')
const PeepsView = require('./peepsView')

console.log('The chitter app is running');

Loading