microsoft / microsoft/typespec
Compile time variables
Open
design:needed
triaged:core
- Dominant language
- Java
- Stars
- 5.9k
- Forks
- 394
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 104
Description
### Discussed in https://github.com/microsoft/typespec/discussions/2915
Originally posted by **laduke** February 14, 2024
I for example, want to pass a version into my service definition
```
@service({
title: "My Service",
version: {VersionFromSomewhere},
})
```
I can get the value into an env var, a cli flag, even a .js file, but I haven't been able to figure out how to import/ interpolate it into the tsp file.
Contributor guide
Assessment
This issue has not been assessed yet.