Is it possible to extract a "subtype"?
Error internationalization (i18n)
Tried to initialize an $ark registry in a monorepo
pnpm workspace, I have 2 packages depending on arktype. This means that each package depends on arktype separately. However, when I import them into a central vite project, I get the error:
```
Tried to initialize an $ark registry but one already existed. This probably means you are either depending on multiple versions of an arktype package, or importing the same package from both ESM and CJS.
Review package.json versions across your repo to ensure consistency....Adding comment to object key
/**  */?
I tried this, but it didn't work:
```ts
output: type({...Optional key
Convert string to number with constraints
Are there examples of how to create mapped types?
{ [K in <SomeOtherType>]: SomeValueType } type, where SomeValueType is either a static type or is computed from K.
I currently have a very basic setup where I have:
```ts
type MappedEnum<T extends string> = { readonly [K in T]: T };...ArkType mutates original input?
How to accept a generic non-empty const string array for use in `type`?
PgEnum<TValues extends [string, ...string[]]> { enumValues: TValues; }
I'm attempting to create a function which accepts this object and returns an arktype instance of the union of the strings in the array, which is const with well-known values....using an const array as a source for a string literal union
ParseError: Root of kind union should be one of alias,intersection,unit,domain,proto
Type Magic: validation on type property
Usage for HTTP validation
reject unknownKeys so invalid requests are immediately 422
- Response should be validated with deep delete unknownKeys so local information can't passthrough
- Response input should be cloned rather then inline-morphed (including key deletion) so you can pass in input objects as-is...Can you create types with dynamic literals?
Cannot assign to Type
How to validate `Record<string, string>`?
Property 'name' is missing in type
Type 'distillOut<T>' is not assignable to type 'T'.
Wrapper around `type()`
Runtime coercion
typeJson at runtime to build accessors for each field, such as joining field names with __ to build environment variable keys, and that is working great. I can cleanly detect when I reach a "leaf" type to load, and I either have a string or an object with a "domain"; my challenge is whether there is an elegant way of coercing the string I load into the type expected at this point (without making some huge imperative logic block).
I'm hopeful there might be some clever thing under the hood that I can use in place of rolling my own....