MCPcopy
hub / github.com/PaulLeCam/react-leaflet / createTileLayerComponent

Function createTileLayerComponent

packages/core/src/generic.ts:102–116  ·  view source on GitHub ↗
(
  createElement: (
    props: PropsWithoutRef<P>,
    context: LeafletContextInterface,
  ) => LeafletElement<E>,
  updateElement?: (
    instance: E,
    props: PropsWithoutRef<P>,
    prevProps: PropsWithoutRef<P>,
  ) => void,
)

Source from the content-addressed store, hash-verified

100}
101
102export function createTileLayerComponent<E extends Layer, P extends LayerProps>(
103 createElement: (
104 props: PropsWithoutRef<P>,
105 context: LeafletContextInterface,
106 ) => LeafletElement<E>,
107 updateElement?: (
108 instance: E,
109 props: PropsWithoutRef<P>,
110 prevProps: PropsWithoutRef<P>,
111 ) => void,
112) {
113 const useElement = createElementHook(createElement, updateElement)
114 const useLayer = createLayerHook(useElement)
115 return createLeafComponent(useLayer)
116}

Callers 3

generic.tsxFile · 0.90
TileLayer.tsxFile · 0.90
WMSTileLayer.tsxFile · 0.90

Calls 3

createElementHookFunction · 0.85
createLayerHookFunction · 0.85
createLeafComponentFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…