We have the below code
var itemType = $models.getItemType(selection.getItem(0));
if itemType == $const.ItemType.COMPONENT
I want to check which schema is used for this component, based on this I want to enable user defined button in the ICM ribbon.
Please share the code how to check the component based on particular schema in JavaScript.