MCPcopy Index your code
hub / github.com/reactopt/reactopt / normalizeOptions

Function normalizeOptions

src/normalizeOptions.js:25–43  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

23};
24
25var normalizeOptions = function normalizeOptions() {
26 var opts = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0];
27 var _opts$include = opts.include;
28 var include = _opts$include === undefined ? [DEFAULT_INCLUDE] : _opts$include;
29 var _opts$exclude = opts.exclude;
30 var exclude = _opts$exclude === undefined ? [DEFAULT_EXCLUDE] : _opts$exclude;
31 var _opts$groupByComponent = opts.groupByComponent;
32 var groupByComponent = _opts$groupByComponent === undefined ? true : _opts$groupByComponent;
33 var _opts$collapseComponentGroups = opts.collapseComponentGroups;
34 var collapseComponentGroups = _opts$collapseComponentGroups === undefined ? true : _opts$collapseComponentGroups;
35 var _opts$notifier = opts.notifier;
36
37 return {
38 include: toArray(include).map(toRegExp),
39 exclude: toArray(exclude).map(toRegExp),
40 groupByComponent: groupByComponent,
41 collapseComponentGroups: collapseComponentGroups
42 };
43};
44exports.normalizeOptions = normalizeOptions;

Callers

nothing calls this directly

Calls 1

toArrayFunction · 0.85

Tested by

no test coverage detected