Skip to content

Instantly share code, notes, and snippets.

View coleenhuang's full-sized avatar

coleenhuang

View GitHub Profile

Source

Vim Commands Cheat Sheet


How to Exit

:q[uit]

@coleenhuang
coleenhuang / rendering a component n times
Created July 30, 2020 02:41
How to render a component x times with Jsx
//making a loop and putting return statements in it doesn't work
//Need to put the components into an array first before rendering
//This is the right way to do it
let cardList = [];
for (let i=0; i < num; i++) {
cardList.push(<Card key={i} />)
}
return <div>{cardList}</div>
Install pg, knex, postgrator-cli
npm i pg knex
npm i postgrator-cli -D
Create Dev and Test DB for project
createdb -U <username> <project-name-dev>
createdb -U <username> <project-name-test> or
postgres=# CREATE ROLE kevin WITH LOGIN;
postgres=# CREATE DATABASE tax_returns OWNER kevin;
Label missing for country
Bug for whether you need bike light or not
Formatting issues for weather
Text too small and difficult to read.
<select id="country" name="country" class="form-control">
<option value="Afghanistan">Afghanistan</option>
<option value="Åland Islands">Åland Islands</option>
<option value="Albania">Albania</option>
<option value="Algeria">Algeria</option>
<option value="American Samoa">American Samoa</option>
<option value="Andorra">Andorra</option>
<option value="Angola">Angola</option>
<option value="Anguilla">Anguilla</option>
<option value="Antarctica">Antarctica</option>
Screen Inventory
Start Screen
Date Selection page
Current weather page
Future weather page
@coleenhuang
coleenhuang / User Stories for Bike Weather App
Created November 1, 2019 04:28
User Stories for Bike Weather App
Role Task Importance
All Users Enter a location High
All Users Select whether they want to see current or future weather conditions High
All Users See whether they should bring a bike light High
All Users See whether they should wear some sun screen Medium
All Users See whether they should bring a jacket and some gloves High
All Users See the high and low temperatures of the desired day Medium
User wants current conditions See current temperature High
User wants current conditions See if the moon is visible and what phase it is at Low
User wants current conditions See current weather outside Medium
1. Yes, most requests require authentication
2. Yes, CORS is supported by the API.
3. The response format is in JSON.
4. The limitation is that if you make too many requests in a short time frame you get throttled, but if this continues to happen you eventually get blocked.
5. The erros expected are: 400 Bad Request, 401 Unauthorized, 429 Too Many Requests, 500 Internal Server Error.
Clients are the people in the library, doing research, while the server is the library, which provides the books and information that the clients request.
@coleenhuang
coleenhuang / Portfolio site contents
Created September 29, 2019 15:21
Text for portfolio site
Headline
Hi, I’m Coleen Huang. I’m a web developer based in the Sacramento Area.
Bio
If you asked any of my friends to describe me, they would say that I’m a bibliophile, avid baker and someone who loves trying out different things.
I love coding, not only because of the opportunities that it gives me to learn and experiment, but also the satisfaction that I feel when I see my ideas come to life. I often feel like I never have time, as there’s so much that I want to learn. The current things that I’m working on mastering are coding, calligraphy and Ancient Greek.
Projects
Project title: Ancient Greece quiz app
Project description: Inspired by my love for Classics and Ancient Greece, I created this quiz app to test people on trivia about Ancient Greece