Squashed 'lib/json-patch/' content from commit e61a128

git-subtree-dir: lib/json-patch
git-subtree-split: e61a128514e0c92f4efccb61a3ea4bc28a7d16df
Merge commit 'a08212d1c6791ff0c498c12f61d055ce6ed61daa' as 'lib/json-patch'
local hotfix: add method unobserve
initial working version of PuppetJs
add dependencies and testing
add some basic usage information
handle Location header (and Location cookie failover); send back X-Referer header; basic error handling
handle HTTP error status codes (4xx, 5xx)
fix jsonpatch.unobserve (non-native)
export unobserve to CommonJs module
read Location cookie from main HTML request and from any following XHR request
fault tolerance - empty response string should be treated as empty patch array
remove path part from `createCookie`. PuppetJs will use domain cookie if any
additional cookie fixes (use root path for cookie)