http://stackoverflow.com/questions/26739167/jwt-json-web-token-automatic-prolongation-of-expiration
This file contains hidden or 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 Nokogiri::XML::SAX::Parser (event-driven parser) and Nokogiri::XML::SAX::Document | |
require 'nokogiri' | |
class IDCollector < Nokogiri::XML::SAX::Document | |
attr :ids | |
def initialize | |
@ids = [] | |
@inside_id = false |
This file contains hidden or 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
echo -n $'\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x01\x03\x62\x61\x64\x00\x00\xf9\x00\x01\x03\x62\x61\x64\x00\x00\x10\x00\x01\x00\x00\x00\xc8\x00\x06\x05\x68\x65\x6c\x6c\x6f' | nc -u localhost 53 |
This file contains hidden or 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 API = { | |
get: function() { | |
return new Promise(function() { | |
// ... some code to get remotely | |
}); | |
} | |
} | |
var UserAPI = { | |
getById: function(id) { |
This file contains hidden or 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
[1,2,3] |> Enum.map(&(IO.inspect(&1))) |
This file contains hidden or 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
// calling setProps is not good practice | |
// instead render the component outside of the react loop | |
React.render( | |
myComponent({ data: someData2 }), | |
document.getElementById('predictionContent') | |
); |