curl --include -i -H "Authorization: Token token=token-goes-here" 'http://example.com'
This file contains 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
I know you've done everything possible to get to where you are in Ruby and in Dutch in a really short timeframe. | |
And no matter what anyone else says, | |
and no matter how anyone treats you, | |
you can know that you are putting the effort in, | |
and you've accomplished so much. | |
I'm more and more impressed every day. | |
Honestly, you've given me renewed drive to improve my development skills. |
This file contains 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
$ Mongoid::VERSION | |
=> "4.0.2" | |
$ Mongoid::Sessions.default[:delivery_addresses].rename(:banned_addresses) | |
=> {"ok"=>1.0} |
This file contains 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
results = Merchant.collection.aggregate([ | |
{ "$group" => { | |
_id: { "confirmation_token" => "$confirmation_token"}, | |
recordIds: {"$addToSet" => "$_id" }, | |
count: { "$sum" => 1 } | |
}}, | |
{ "$match" => { | |
count: { "$gt" => 1 } | |
}} | |
]) |
This file contains 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
var debug = process.env.NODE_ENV !== "production"; | |
var webpack = require('webpack'); | |
module.exports = { | |
context: __dirname, | |
devtool: debug ? "inline-sourcemap" : null, | |
entry: "./js/scripts.js", | |
output: { | |
path: __dirname + "/js", | |
filename: "scripts.min.js" |
This file contains 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 from "react"; | |
import { render } from "react-dom"; | |
const ParentComponent = React.createClass({ | |
getDefaultProps: function() { | |
console.log("ParentComponent - getDefaultProps"); | |
}, | |
getInitialState: function() { | |
console.log("ParentComponent - getInitialState"); | |
return { text: "" }; |
const/let are block scoped (meaning anywhere we have an opening and closing curly brace we're creating a new scope).
It's generally agreed upon that block scope is a better paradigm than function scope which is why organizations like Mozilla have been primarily using let internally for years. Now that brings us to const. Everything let has, const also has. The only difference is that when you create a variable with const, that variable can't be re-assigned a new reference. Notice I didn't say that variable is immutable.
https://docs.docker.com/mac/step_one/
$ docker-compose build
$ docker-compose up
- More info: docker-compose up
This file contains 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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
OlderNewer