mirror of
https://github.com/koel/koel
synced 2024-12-19 17:13:09 +00:00
9 lines
182 B
TypeScript
9 lines
182 B
TypeScript
export const use = <T>(value: T, cb: (arg: T) => void): void => {
|
|
if (typeof value === 'undefined' || value === null) {
|
|
return
|
|
}
|
|
|
|
cb(value)
|
|
}
|
|
|
|
export const noop = () => {}
|