Control generation of custom types
@jmac03 is already working on this.
Since Sep 24, 2026.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 48/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- elixir, typescript
- Domain
- backend-api-design, devtools
Research direction
Start by reading the custom type example in the linked ash_object_ids lib/type.ex file and inspect how this project turns custom Ash types into generated Zod schemas. Trace the path that currently emits z.any(); done means a custom type can provide its own TypeScript name and formatting behavior instead of always becoming z.any().
Written by the indexing model from the issue text.
Description
Code of Conduct
- I agree to follow this project's Code of Conduct
AI Policy
- I agree to follow this project's AI Policy, or I agree that AI was not used while creating this issue.
Is your feature request related to a problem? Please describe.
I use custom types to define a per-resource ID (ash_object_ids). These custom types currently result in z.any() in the generated zod schema.
Describe the solution you'd like
Custom types can determine themselves how they should be generated. Perhaps something like
defmodule MyCustomType do
use Ash.Type
# ...
def typescript_type_name, do: "MyCustomType"
def typescript_format_type(formatter), do: ...
end
Describe alternatives you've considered
No response
Additional context
https://github.com/drtheuns/ash_object_ids/blob/main/lib/type.ex#L15
- Dominant language
- Elixir
- Stars
- 103
- Forks
- 36
- Avg merge
- 1m
- Merged PRs (30d)
- 1
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from ash-project/ash_typescript
-
Difficulty 2/5 1-3 hours Newbie friendliness 69/100
ash-project/ash_typescript#114 · 1 comment ·
-
Generated channel client fails noUnusedLocals without hooksPossibly taken @mossygrave claimed this 6 days ago. Openbug
Difficulty 3/5 1-2 days Newbie friendliness 72/100
ash-project/ash_typescript#112 · 2 comments ·
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 25/100
ash-project/ash_typescript#103 · 2 comments ·
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 42/100
ash-project/ash_typescript#51 · 2 comments · 3 reactions ·
All issues in ash-project/ash_typescript
Similar issues
-
@swmansion/popcorn: published .d.ts files lack extensions on relative imports, breaking moduleResolution node16/nodenextPossibly taken @Huyvux12 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
software-mansion/popcorn#929 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
ash-project/ash#3127 ·
Maintainers usually reply within 1 day
-
Bug: Table layout and date column are cut off on mobile screens on the Tournaments -> History pageOpenbug
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
hexlet-codebattle/codebattle#2375 ·
-
Bug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
wintermeyer/vutuv#2388 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100