Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export const initLayerInSeer = layer => {
if (!seer.isReady() || !layer) {
return;
}
const badges = [layer.constructor.layerName];
seer.listItem('deck.gl', layer.id, {
badges,
// TODO: Seer currently only handles single model layers
links: layer.state && layer.state.model ? [`luma.gl:${layer.state.model.id}`] : undefined,
parent: layer.parent ? layer.parent.id : undefined
});
};
export const addModel = model => {
if (models[model.id]) {
return;
}
models[model.id] = model;
seer.listItem('luma.gl', model.id);
};