MCPcopy Index your code
hub / github.com/Effect-TS/effect / nonEmptyString

Function nonEmptyString

packages/effect/src/Schema.ts:4658–4665  ·  view source on GitHub ↗
(
  annotations?: Annotations.Filter<Schema.Type<S>>
)

Source from the content-addressed store, hash-verified

4656 * @since 3.10.0
4657 */
4658export const nonEmptyString = <S extends Schema.Any>(
4659 annotations?: Annotations.Filter<Schema.Type<S>>
4660): <A extends string>(self: S & Schema<A, Schema.Encoded<S>, Schema.Context<S>>) => filter<S> =>
4661 minLength(1, {
4662 title: "nonEmptyString",
4663 description: "a non empty string",
4664 ...annotations
4665 })
4666
4667/**
4668 * This schema converts a string to lowercase.

Callers 2

NonEmptyStringClass · 0.70

Calls 1

minLengthFunction · 0.85

Tested by

no test coverage detected