Map the schema's events to the generator's event-entry shape.
(schema)
| 727 | |
| 728 | /** Map the schema's events to the generator's event-entry shape. */ |
| 729 | function schemaToEvents(schema) { |
| 730 | return schema.events.map((e) => ({ |
| 731 | domain: e.domain, |
| 732 | methodStr: e.method, |
| 733 | eventName: e.name, |
| 734 | paramsTypeName: e.params ? normalizeDottedName(e.params.ref) : null, |
| 735 | })) |
| 736 | } |
| 737 | |
| 738 | // ============================================================ |
| 739 | // Code generation |
no test coverage detected