mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-03 18:41:15 +08:00
This updates Rollup, SVGO and clean-css. Only clean-css had reported breaking changes, but we are not affected (Node compatibility removals and changes to features we don't use). R=jacktfranklin@chromium.org Bug: none Change-Id: I94c293e128d1ddb81f12036421a715da210e7633 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3060704 Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org> Reviewed-by: Paul Lewis <aerotwist@chromium.org>
26 lines
733 B
JavaScript
26 lines
733 B
JavaScript
function pluginsFrom(plugins) {
|
|
var flatPlugins = {
|
|
level1Value: [],
|
|
level1Property: [],
|
|
level2Block: []
|
|
};
|
|
|
|
plugins = plugins || [];
|
|
|
|
flatPlugins.level1Value = plugins
|
|
.map(function (plugin) { return plugin.level1 && plugin.level1.value; })
|
|
.filter(function (plugin) { return plugin != null; });
|
|
|
|
flatPlugins.level1Property = plugins
|
|
.map(function (plugin) { return plugin.level1 && plugin.level1.property; })
|
|
.filter(function (plugin) { return plugin != null; });
|
|
|
|
flatPlugins.level2Block = plugins
|
|
.map(function (plugin) { return plugin.level2 && plugin.level2.block; })
|
|
.filter(function (plugin) { return plugin != null; });
|
|
|
|
return flatPlugins;
|
|
}
|
|
|
|
module.exports = pluginsFrom;
|