Bringing it all together
You'll revisit these!
var pg = require('pg');
var db;
pg.connect("postgres://localhost:5432/pokemon", function(err, client, done) {
db = client;
});
In your node REPL:
In an empty folder:
npm init
npm install pg --save
db.query("SELECT * FROM pokemon;", function (err, rows) {
});
This is revisiting Post It, time for a CFU
What is Something?
Where would we use Something?
3 ways to refactor your last project into Something-style
You can use the technique Cold Calling
You can also use Turn and Talk, Batch Process, or Think Pair Share
Setup
Something else
What does this evaluate to?
Revisiting Post It!
Time for a CFU!
Show how to use Something Else on your whiteboards
How do we use Something Else with Something?
This technique is called Everybody Writes
This technique is called Name The Steps
Anytime you Name The Steps, make them write it with BOARD = PAPER
This technique is called Name The Steps
They should write it down, the BOARD = PAPER techique
10 Minutes: try to do Something
10 Minutes: Do Something Else, Recursively
25 Minutes: Use Some Other Thing to fix the problem with Something Else
This technique is called Brighten Lines