Show full path in finder
defaults write com.apple.finder _FXShowPosixPathInTitle -bool YES
<?php | |
/** | |
* ACF Layout | |
* @version 1.0 | November 12th 2013 | |
* @author Beau Charman | http://twitter.com/beaucharman | |
* @link https://gist.github.com/beaucharman/7181406 | |
* @license MIT license | |
* | |
* Logical layout automation for Advanced Custom Fields and it's Flexible Content Field add on. |
function throttle(callback, wait, immediate = false) { | |
let timeout = null | |
let initialCall = true | |
return function() { | |
const callNow = immediate && initialCall | |
const next = () => { | |
callback.apply(this, arguments) | |
timeout = null | |
} |
function debounce(callback, wait, immediate = false) { | |
let timeout = null | |
return function() { | |
const callNow = immediate && !timeout | |
const next = () => callback.apply(this, arguments) | |
clearTimeout(timeout) | |
timeout = setTimeout(next, wait) |
function safeSplice(array, start, deleteCount, ...replace) { | |
const removed = array.splice(start, deleteCount, ...replace) | |
return { | |
array: array, | |
removed: removed, | |
} | |
} | |
/** usage | |
const array = [1, 2, 3, 4, 5, 6] |
unless(booleanExpression, () => { | |
// Then callback | |
}) |
// Portal_Teams.addTeamMember.request.js | |
{ | |
... | |
data: { | |
ClassName: 'Platform_Teams', | |
MethodName: 'addTeamMember', | |
Parameter: { | |
name: 'Name', | |
practitionerId: '0050k000000FtmGAAS', | |
clients: [ // Group and all it's entities |
git checkout <master>
git merge origin <master>
git checkout <feature>
git rebase <master>
git add .
git rebase --continue
git push origin <feature> --force
// const { unionBy, isArray, merge, find } = _ | |
const deepArrayMerge = (initial, replacement, key) => unionBy(initial, replacement, key) | |
.map(item => merge({}, item, find(isArray(replacement) ? replacement : [replacement], { [key]: item[key] }))) |