@graphty/graphty-element / catalog / formatDescriptor
Function: formatDescriptor() ​
formatDescriptor(
id):FormatDescriptor|undefined
Defined in: graphty-element/src/catalog/formats.ts:547
Find one format's descriptor by its name.
The element's own table is searched first and the registrations second, so a built-in name always means what it has always meant and a registered format is still found by the name a consumer typed or a saved document recorded. A lookup that missed registrations would leave the extension point half-built: the format would appear in a picker and then fail when it was chosen.
Parameters ​
id ​
string
The format name, such as "graphml".
Returns ​
FormatDescriptor | undefined
The descriptor, or undefined when neither the element nor a registration knows that format.