MCPcopy Create free account
hub / github.com/didi/mpx / fillInComponentsMap

Function fillInComponentsMap

packages/webpack-plugin/lib/react/processJSON.js:54–66  ·  view source on GitHub ↗
(name, entry, tarRoot)

Source from the content-addressed store, hash-verified

52 const stringifyRequest = r => loaderUtils.stringifyRequest(loaderContext, r)
53
54 function fillInComponentsMap (name, entry, tarRoot) {
55 const { resource, outputPath } = entry
56 const { resourcePath } = parseRequest(resource)
57 componentsMap[resourcePath] = outputPath
58 loaderContext._module && loaderContext._module.addPresentationalDependency(new RecordResourceMapDependency(resourcePath, 'component', outputPath))
59 localComponentsMap[name] = {
60 resource: addQuery(resource, {
61 isComponent: true,
62 outputPath
63 }),
64 async: tarRoot
65 }
66 }
67
68 const {
69 isUrlRequest,

Callers 1

processComponentsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected