Skip to content

Fix Metadata.generator.version type: number → string #150

Description

@nathanacurtis

Summary

Metadata.generator.version is typed as number in packages/schema/types/Metadata.ts, but since #121 the plugin and CLI both pass semver strings (e.g. "1.10.0"). This causes a type error in specs-from-figma build:types and is incorrect relative to actual usage.

Fix

Change generator.version from number to string in packages/schema/types/Metadata.ts and update the JSON schema accordingly.

Context

Introduced when __PLUGIN_VERSION__ was changed from a hardcoded integer to a build-time semver string define. The CLI also passes a semver string via RestFoundations.generator. The field has been effectively a string since v0.22.0 / v0.19.0 — the type just hasn't caught up.

Metadata

Metadata

Assignees

Labels

schemaspecs-schema types and JSON schema

Type

No type
No fields configured for issues without a type.

Projects

Status
Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions