Skip to content

Instantly share code, notes, and snippets.

Carbide Public carbide-public

View GitHub Profile
View cell0.js
///ssssconsole.log("googgl")
View cell0.js
const cloneActionWithUser = (action, user) => {
const thunk = action.call({})
thunk.user = user;
return (a) => {
return thunk
}
}
const user = {token: 123 }
View cell0.js
const test = (a, b) => {
console.log(b)
return a
}
const cloneFunction = (action, user) => {
const clonedAction = action.bind({ })
clonedAction.user = user;
return clonedAction;
View cell0.js
const data = [
{id: 1, nama: 'wildan'},
{id: 1, nama: 'dika'},
]
const dataLoop = data.forEach(function (value, index) {
return index
})
console.log(dataLoop)
View cell0.js
import pick from 'lodash/pick';
const foo = {
View cell0.js
import pick from 'lodash.pick';
const foo = {
a: 'a',
b: 'b'
};
const bar = pick(foo, ['a', 'b'])
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.