This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| body { | |
| background-color: #160507; | |
| } | |
| .App { | |
| height: 95%; | |
| width: 93vw; | |
| margin: 10px; | |
| display: flex; | |
| padding: 10px; | |
| text-align: center; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [ | |
| { | |
| "id": 1, | |
| "first_name": "Carmelina", | |
| "last_name": "Peasey", | |
| "email": "cpeasey0@bloglovin.com", | |
| "gender": "Female", | |
| "ip_address": "155.168.48.181", | |
| "avatar_url": "https://robohash.org/necessitatibuseiusquasi.png?size=50x50&set=set1", | |
| "last_message_content": "Curabitur at ipsum ac tellus semper interdum. Mauris ullamcorper purus sit amet nulla. Quisque arcu libero, rutrum ac, lobortis vel, dapibus at, diam.", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export const CITIES = [ | |
| { | |
| name: "Saigon", | |
| latitude: 10.817141, | |
| longitude: 106.707954, | |
| imgUrl: [ | |
| "http://i.imgur.com/99KyJ5N.jpg", | |
| "https://wallpapercave.com/wp/wp4190043.jpg", | |
| "https://mfiles.alphacoders.com/701/701818.jpg", | |
| "https://mfiles.alphacoders.com/702/702637.jpg", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { useState, useEffect } from 'react'; | |
| import './App.css'; | |
| function App() { | |
| const [cart, setCartItem] = useState({ items: [] }) | |
| const getCart = async() => { | |
| const cart = await localStorage.getItem('cart') | |
| if (cart) { | |
| const cartObject = { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const people = [ | |
| { | |
| id: 1, | |
| firstName: "Loi", | |
| lastName: "Tran", | |
| age: 18, | |
| favoriteColor: "red", | |
| favoriteColors: ["red", "white", "blue"], | |
| favoriteSingers: ["Mariah Carey", "Justin Bieber", "Britney Spears"], | |
| nationality: "U.S.A.", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| document.getElementById("todoInput").focus() | |
| const node = document.getElementById("todoInput"); | |
| node.addEventListener("keyup", (e) => { | |
| if (e.key === "Enter") { | |
| addTodo() | |
| } | |
| }); | |
| const todos = [ | |
| { done: true, body: 'Go to School'}, | |
| { done: false, body: 'Have some coffee'}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>Todo List</title> | |
| <meta name="description" content="Todo List"> | |
| <meta name="author" content="SitePoint"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const girlfriends = [ | |
| { isHappy: false, name: 'Binna', likesMovies: false, likesFlowers: true, favoriteFlowerColor: 'red' }, | |
| { isHappy: true, name: 'Vivian', likesMovies: false, likesFlowers: true }, | |
| { isHappy: false, name: 'Tram', likesMovies: true, likesFlowers: false }, | |
| { isHappy: true, name: 'Diep', likesMovies: true, likesFlowers: true }, | |
| ] | |
| function takeToMovie(girlfriend) { | |
| console.log('Loi is taking ' + girlfriend.name + ' to the movies') | |
| } | |
| function buyFlowers(girlfriend) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const http = require('http'); | |
| const request = require('request'); | |
| require('dotenv').config(); | |
| const clientId = process.env.REACT_APP_CLIENT_ID; | |
| const secretKey = process.env.REACT_APP_SECRET_KEY; | |
| console.log('started server on port 5000'); | |
| http.createServer((req, res) => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "candidates": [ | |
| { | |
| "id": 69, | |
| "first_name": "Carola", | |
| "last_name": "Linsley", | |
| "email": "clinsley1w@businessweek.com", | |
| "gender": "Female", | |
| "country": "Brazil", | |
| "job_title": "VP Marketing", |