Skip to content

Commit ed67018

Browse files
author
Night Knight
committed
replace Object.values with lodash.values
1 parent 34fb87a commit ed67018

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { resolve, dirname, relative, join, parse } from 'path';
44
import { optimize, LoaderTargetPlugin, JsonpTemplatePlugin } from 'webpack';
55
import { ConcatSource } from 'webpack-sources';
66
import globby from 'globby';
7-
import { defaults } from 'lodash';
7+
import { defaults, values } from 'lodash';
88
import MultiEntryPlugin from 'webpack/lib/MultiEntryPlugin';
99
import SingleEntryPlugin from 'webpack/lib/SingleEntryPlugin';
1010
import FunctionModulePlugin from 'webpack/lib/FunctionModulePlugin';
@@ -154,7 +154,7 @@ export default class WXAppPlugin {
154154
const { usingComponents = {} } =
155155
await readJson(`${instance}.json`).catch(::console.error);
156156
const componentBase = parse(instance).dir;
157-
for (const relativeComponent of Object.values(usingComponents)) {
157+
for (const relativeComponent of values(usingComponents)) {
158158
const component = resolve(componentBase, relativeComponent);
159159
if (!components.has(component)) {
160160
components.add(relative(this.base, component));

0 commit comments

Comments
 (0)