Skip to main content

isComponentType()

Home > @backstage/plugin-catalog > isComponentType

For use in EntitySwitch.Case. Matches if the entity is a Component of a given spec.type.

Signature:

function isComponentType(types: string | string[]): (entity: Entity) => boolean;

Parameters

Parameter

Type

Description

types

string | string[]

**Returns:**

(entity: Entity) => boolean