sam-goodwin / eventual

Build scalable and durable micro-services with APIs, Messaging and Workflows
https://docs.eventual.ai
MIT License
174 stars 4 forks source link

fix: all resources have name type param #357

Closed thantos closed 1 year ago

thantos commented 1 year ago

They were all using the types with logic to check for "same as export name" and "different from export name".

When the Resource["name"] resolved to a string, it is always considered to be the same as the export name. (exportName extends string). Now that a type parameter is used for name in the interfaces/specs, the export name is compared to the string literal type and not string (exportName extends Name).

These all work the same as commands, tasks, and subscriptions.

For:

image

Before change:

image

After change:

image