Linting rule against non model response
- Dominant language
- TypeScript
- Stars
- 27
- Forks
- 90
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 156
Description
Copied from https://github.com/Azure/typespec-azure-pr/issues/2600
```
op world(): MyEnum;
```
returns a string. It should be disallowed.
General request is: If the return type is not a model, then it should be disallowed.
> I'd be fine with a rule that flags a non-model return type for application/json.
> from @mikekistler
Contributor guide
Research direction
No implementation files or tests are named. Start by locating the existing lint-rule entry points and tests for operation return types, then determine how application/json responses are represented. Done means the rule flags operations returning a non-model type, such as MyEnum, while the expected model-returning cases remain valid.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100