* Add a set of configurations and record the source * * @param {string=} name an entry will be added to sources under this name (if given) * @param {object=} values values to merge in * @param {string=} original Optional unparsed version of the data * @return {Load} this
(name, values, original)
| 1074 | * @return {Load} this |
| 1075 | */ |
| 1076 | addConfig(name, values, original) { |
| 1077 | this.updated = true; |
| 1078 | |
| 1079 | Util.extendDeep(this.config, values); |
| 1080 | |
| 1081 | if (name && this.sources) { |
| 1082 | let source = {name, parsed: values}; |
| 1083 | |
| 1084 | if (original !== undefined) { |
| 1085 | source.original = original; |
| 1086 | } |
| 1087 | |
| 1088 | this.sources.push(source); |
| 1089 | } |
| 1090 | |
| 1091 | return this; |
| 1092 | } |
| 1093 | |
| 1094 | |
| 1095 | /** |
no test coverage detected