Span overview
Added in v1.0.0
Table of contents
combinators
concat
Signature
export declare const concat: { (that: Span): (self: Span) => Span; (self: Span, that: Span): Span }
Added in v1.0.0
spans
Signature
export declare const spans: (spans: Iterable<Span>) => Span
Added in v1.0.0
constructors
code
Signature
export declare const code: (value: string | Span) => Span
Added in v1.0.0
empty
Signature
export declare const empty: Span
Added in v1.0.0
error
Signature
export declare const error: (value: string | Span) => Span
Added in v1.0.0
space
Signature
export declare const space: Span
Added in v1.0.0
strong
Signature
export declare const strong: (value: string | Span) => Span
Added in v1.0.0
text
Signature
export declare const text: (value: string) => Span
Added in v1.0.0
uri
Signature
export declare const uri: (value: string) => Span
Added in v1.0.0
weak
Signature
export declare const weak: (value: string | Span) => Span
Added in v1.0.0
models
Highlight (interface)
Signature
export interface Highlight {
readonly _tag: "Highlight"
readonly value: Span
readonly color: Color
}
Added in v1.0.0
Sequence (interface)
Signature
export interface Sequence {
readonly _tag: "Sequence"
readonly left: Span
readonly right: Span
}
Added in v1.0.0
Span (type alias)
Signature
export type Span = Highlight | Sequence | Strong | Text | URI | Weak
Added in v1.0.0
Strong (interface)
Signature
export interface Strong {
readonly _tag: "Strong"
readonly value: Span
}
Added in v1.0.0
Text (interface)
Signature
export interface Text {
readonly _tag: "Text"
readonly value: string
}
Added in v1.0.0
URI (interface)
Signature
export interface URI {
readonly _tag: "URI"
readonly value: string
}
Added in v1.0.0
Weak (interface)
Signature
export interface Weak {
readonly _tag: "Weak"
readonly value: Span
}
Added in v1.0.0
refinements
isSequence
Signature
export declare const isSequence: (self: Span) => self is Sequence
Added in v1.0.0
isStrong
Signature
export declare const isStrong: (self: Span) => self is Strong
Added in v1.0.0
isText
Signature
export declare const isText: (self: Span) => self is Text
Added in v1.0.0
isUri
Signature
export declare const isUri: (self: Span) => self is URI
Added in v1.0.0
isWeak
Signature
export declare const isWeak: (self: Span) => self is Weak
Added in v1.0.0