Skip to content

Instantly share code, notes, and snippets.

View brittanydionigi's full-sized avatar

Brittany Dionigi brittanydionigi

View GitHub Profile
@brittanydionigi
brittanydionigi / googlemap.html
Last active June 30, 2020 21:42
pin cities on a google map based on city name & country
<!doctype>
<html>
<head>
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<title>Google Maps - pin cities</title>
<style type="text/css">
html, body { height: 100%; margin: 0; padding: 0; }
#map_canvas { height: 100%; }
</style>
<html>
<head>
<style type="text/css">
#main { padding: 100px; border: 2px solid pink; }
.blue { background-color: blue; }
</style>
</head>
<body>
<div id="main">Lorem ipsum dolor!</div>
<script type="text/javascript">
if body.Status == nil {
body.Status = "ACTIVE"
}
# invalid operation: body.Status == nil (mismatched types string and nil)
@brittanydionigi
brittanydionigi / initializing-new-repos.md
Last active November 13, 2019 14:24
Tips for Initializing a new repo

These instructions are for whichever group member is going to create the GitHub repo under their account. Other groups members will collaborate after these steps have been completed by one member of the group. You should still step through these together so everyone is aware of what goes into setting up a new repo.

Creating the GitHub Repo

  • Use the GitHub UI to create a new repo, and make sure you initialize it with a README and a .gitignore file. You can select a preset .gitignore file from the dropdown menu. Node is usually a good one to choose. (Feel free to read more about gitignore files here). You can disregard the 'Add license' option.

  • Make sure your repo has a relevant title and description. If you ultimately deploy your application so that it has a URL, you'll want to update your description to include a link to the deployed version.

new-repo

## Data
`score: 90%`
`name: 'Brittany'`
`assignedReviewer: 'Devon'`
`name: 'Devon'`
`studentName: 'Brittany'`
`status: 'accepted/deferred/pending'`
@brittanydionigi
brittanydionigi / myjQuery.js
Created July 9, 2019 14:20
little pretend jQuery
function $(selector) {
function selectWithJS() {
let selectorType = selector.split('').shift();
let selectorName = selector.substr(1);
if (selectorType === '#') {
return document.getElementById(selectorName);
} else {
return document.querySelectorAll(selectorName);
}

Goals

By the end of this lesson, you will be able to:

  • Understand the order of execution for JavaScript code and why it matters
  • Describe the differences between var, let and const and when to use each
  • Predict how variables will behave when multiple scopes are involved

Vocab

Add a link to your github repo for GameTime as a comment on this gist.

@brittanydionigi
brittanydionigi / pizza-party.html
Last active November 28, 2018 17:37
Object & Array Practice
// HTML SECTION
<h1>Papa Turing's Pizza</h1>
<h2>Review Your Order</h2>
<ul id="order-details"></ul>
<button id="submit-order">Place Order</button>
// JAVASCRIPT SECTION
const constellations = {
orion: {
names: ['Orion', 'The Hunter', 'The Giant', 'The Deer'],
stars: ['Betelgeuse', 'Rigel', 'Bellatrix', 'Mintaka', 'Alnilam', 'Alnitak', 'Saiph']
},
ursaMajor: {
names: ['Ursa Major', 'The Big Dipper', 'The Great Bear', 'The Plow'],
stars: ['Dubhe', 'Merak', 'Phecda', 'Megrez', 'Alioth', 'Mizar', 'Alkaid']
},
ursaMinor: {