Skip to content

Instantly share code, notes, and snippets.

View douglasabnovato's full-sized avatar
:octocat:
<Html/><Css/><Javascript/><ReactJS/>

Douglas Antonio Braga Novato douglasabnovato

:octocat:
<Html/><Css/><Javascript/><ReactJS/>
View GitHub Profile
@douglasabnovato
douglasabnovato / modern_js.md
Created November 30, 2022 19:45 — forked from gaearon/modern_js.md
Modern JavaScript in React Documentation

If you haven’t worked with JavaScript in the last few years, these three points should give you enough knowledge to feel comfortable reading the React documentation:

  • We define variables with let and const statements. For the purposes of the React documentation, you can consider them equivalent to var.
  • We use the class keyword to define JavaScript classes. There are two things worth remembering about them. Firstly, unlike with objects, you don't need to put commas between class method definitions. Secondly, unlike many other languages with classes, in JavaScript the value of this in a method [depends on how it is called](https://developer.mozilla.org/en-US/docs/Web/Jav
@douglasabnovato
douglasabnovato / index.html
Created October 28, 2022 13:24 — forked from gaearon/index.html
Add React in One Minute
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>Add React in One Minute</title>
</head>
<body>
<h2>Add React in One Minute</h2>
<p>This page demonstrates using React with no build tooling.</p>
@douglasabnovato
douglasabnovato / index.html
Created October 28, 2022 13:24 — forked from gaearon/index.html
Multiple React components on a single HTML page
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>Add React in One Minute</title>
</head>
<body>
<h2>Add React in One Minute</h2>
<p>This page demonstrates using React with no build tooling.</p>
@douglasabnovato
douglasabnovato / minification.md
Created October 28, 2022 13:24 — forked from gaearon/minification.md
How to Set Up Minification

In production, it is recommended to minify any JavaScript code that is included with your application. Minification can help your website load several times faster, especially as the size of your JavaScript source code grows.

Here's one way to set it up:

  1. Install Node.js
  2. Run npm init -y in your project folder (don't skip this step!)
  3. Run npm install terser

Now, to minify a file called like_button.js, run in the terminal:

@douglasabnovato
douglasabnovato / top_movies.sql
Created November 17, 2020 16:56 — forked from pamelafox/top_movies.sql
Top 100 Movies
/* Source: http://www.boxofficemojo.com/alltime/world/ */
CREATE TABLE topmovies(
Rank INTEGER,
Title TEXT,
Studio TEXT,
Worldwide REAL,
Domestic REAL,
DomesticPct REAL,
Overseas REAL,
OverseasPct REAL,
@douglasabnovato
douglasabnovato / nfl_picks.sql
Created November 17, 2020 16:55 — forked from pamelafox/nfl_picks.sql
nfl_picks.sql
/*
1st 3 rounds of the NFL 2015 Draft
Collected by: https://www.khanacademy.org/profile/BobbyandKaren/
*/
CREATE TABLE picks(
id INTEGER PRIMARY KEY,
pick_number INTEGER,
name TEXT,
college TEXT,
@douglasabnovato
douglasabnovato / card_games_results.sql
Created November 17, 2020 16:55 — forked from pamelafox/card_games_results.sql
card_games_results.sql
/* Friendly Card Game Results:
During this past winter, a few friends got together every Wednesday night for a friendly game of cards. On some nights they'd play two games, but never the same game twice on the same night. The usual players were Spunky Sam, Marcimus, Winston, and Hopper. Sometimes, one of the friends couldn't make it, so there were only three players. But sometimes they'd call another friend to fill-in. In every game they played, the one with the hightest score was declared the winner. These are their results:
Created by: https://www.khanacademy.org/profile/brianduckworth
*/
CREATE TABLE card_games(id INTEGER PRIMARY KEY AUTOINCREMENT,
date_played TEXT,
game_name TEXT,
player_name TEXT,
score INTEGER);
@douglasabnovato
douglasabnovato / winstons_donut_logs.sql
Created November 17, 2020 16:55 — forked from pamelafox/winstons_donut_logs.sql
winstons_donut_logs.sql
/*
Winston's Donut logs
This table of logs shows how many donuts Winston eats at each year of his life,
plus any particular reason to explain his eating habits.
Collected by: https://www.khanacademy.org/profile/mhogwarts/
*/
CREATE TABLE winstons_donut_logs (
id TEXT PRIMARY KEY,
status TEXT,
years_old INTEGER,
@douglasabnovato
douglasabnovato / earned_badges.sql
Created November 17, 2020 16:55 — forked from pamelafox/earned_badges.sql
earned_badges.sql
/*
Earned Badges
This table contains badges earned by a user, including the most recent date achieved, the type, the name, the # of energy points earned, and the activity earned from.
Collected by: https://www.khanacademy.org/profile/chopsor/
*/
CREATE TABLE badges (
date TEXT,
badge_type TEXT,
badge_name TEXT,
@douglasabnovato
douglasabnovato / furniture_store_sales.sql
Created November 17, 2020 16:55 — forked from pamelafox/furniture_store_sales.sql
furniture_store_sales.sql
/*
Sales from an online furniture store
Collected by: https://www.khanacademy.org/profile/charlesb2000/
*/
CREATE TABLE sales(
ID INTEGER NOT NULL PRIMARY KEY
, transaction_date TEXT
, product TEXT
, price INTEGER
, payment_type TEXT