Website Structure
This commit is contained in:
parent
62812f2090
commit
71f0676a62
22365 changed files with 4265753 additions and 791 deletions
18
Frontend-Learner/node_modules/eslint-plugin-import-x/lib/utils/apply-default.js
generated
vendored
Normal file
18
Frontend-Learner/node_modules/eslint-plugin-import-x/lib/utils/apply-default.js
generated
vendored
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
import { deepMerge, isObjectNotArray } from './deep-merge.js';
|
||||
export function applyDefault(defaultOptions, userOptions) {
|
||||
const options = structuredClone(defaultOptions);
|
||||
if (userOptions == null) {
|
||||
return options;
|
||||
}
|
||||
for (const [i, opt] of options.entries()) {
|
||||
if (userOptions[i] !== undefined) {
|
||||
const userOpt = userOptions[i];
|
||||
options[i] =
|
||||
isObjectNotArray(userOpt) && isObjectNotArray(opt)
|
||||
? deepMerge(opt, userOpt)
|
||||
: userOpt;
|
||||
}
|
||||
}
|
||||
return options;
|
||||
}
|
||||
//# sourceMappingURL=apply-default.js.map
|
||||
Loading…
Add table
Add a link
Reference in a new issue