pull-configs

pulls configuration files from a remote location and merges them with local
npm i pull-configs
|
pnpm add pull-configs
|
yarn add pull-configs
|
API
# pullConfigs(remote, local)
src/index.ts#L22 # remote
# local
pullConfigs(remote, local) =>
{ # assign
src/index.ts#L89 {
# target
# source
<T, U>(target, source) =>
# target
# source1
# source2
<T, U, V>(target, source1, source2) =>
# target
# source1
# source2
# source3
<T, U, V, W>(target, source1, source2, source3) =>
# target
# sources
(target, sources) =>
}
# merge
src/index.ts#L89 # (file, replacer)
# file
# replacer(prev, next)
# prev
# next
replacer(prev, next) =>
(file, replacer) =>
# omit
src/index.ts#L89 # (obj, keys)
# obj
# keys
(obj, keys) =>
# pick
src/index.ts#L89 # (obj, keys)
# obj
# keys
(obj, keys) =>
# replace
src/index.ts#L89 # sort
src/index.ts#L89 }
# pullConfigs(remote, local)
src/index.ts#L22 # remote
# local
pullConfigs(remote, local) =>
{ # assign
src/index.ts#L89 {
# target
# source
<T, U>(target, source) =>
# target
# source1
# source2
<T, U, V>(target, source1, source2) =>
# target
# source1
# source2
# source3
<T, U, V, W>(target, source1, source2, source3) =>
# target
# sources
(target, sources) =>
}
# merge
src/index.ts#L89 # (file, replacer)
# file
# replacer(prev, next)
# prev
# next
replacer(prev, next) =>
(file, replacer) =>
# omit
src/index.ts#L89 # (obj, keys)
# obj
# keys
(obj, keys) =>
# pick
src/index.ts#L89 # (obj, keys)
# obj
# keys
(obj, keys) =>
# replace
src/index.ts#L89 # sort
src/index.ts#L89 }
Credits
- json-diff by Andrey Tarantsov – JSON diff
Contributing
Fork or edit and submit a PR.
All contributions are welcome!
License
MIT © 2022 stagas