-
Create a file to store our credentials:
sudo vim /etc/postfix/sasl_passwd
-
Add something like this:
var guid = require('guid'); | |
var listeners = {}; | |
module.exports = { | |
register: function(cb) { | |
var id = guid.raw(); | |
listeners[id] = callback; | |
return id; | |
}, | |
dispatch: function(payload) { |
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
var fs = require('fs') | |
function readfile() { | |
new Promise(function (resolve, reject) { | |
fs.readFile('app/topspots.json', 'utf-8', function (err, file) { | |
if (err) { | |
console.log('Inside Error: ') | |
console.log(err); | |
return reject(err); | |
} |
ESLint is an open source project originally created by Nicholas C. Zakas in June 2013. Its goal is to provide a pluggable linting utility for JavaScript. Adding it to all your projects and setting up a linter plugin in your code editor may help you write more maintainable code.
-
Install the Atom Linter plugin
-
Install the Atom ES-Lint Plugin
const chai = require('chai'); | |
const chaiHttp = require('chai-http'); | |
const expect = chai.expect; | |
chai.use(chaiHttp); | |
const app = require('../server/app'); | |
var mock = []; | |
describe("server module", function() { |
#MongoDB
What is mongo - document based database, no SQL How do you install it by default its not secure, you should add a user and restrict access before production
digital ocean mongo labs using mongoLabs mongo ds021671.mlab.com:21671/sdcs -u michael -p michael
httpClient.DefaultRequestHeaders.Authorization = | |
new AuthenticationHeaderValue( | |
"Basic", | |
Convert.ToBase64String( | |
System.Text.ASCIIEncoding.ASCII.GetBytes( | |
string.Format("{0}:{1}", username, password)))); |
Complete the React Basics course on Team Treehouse, or the equivelant on CodeSchool, PluralSight, etc.
Read Thinking in React and quickly review the React docs.
Watch Thinking in React follow along carefully and if time permits build the project along side watching.