vegan-ipsum
Version:
Generates passages of vegan-themed placeholder text suitable for use in web pages, graphics, and more. Works in the browser, NodeJS, and React Native.
65 lines (64 loc) • 1.8 kB
TypeScript
export declare const FORMAT_HTML = "html";
export declare const FORMAT_PLAIN = "plain";
export declare const FORMATS: string[];
export type LoremFormat = 'plain' | 'html';
/**
* An object representing line endings for different platforms.
*
* - `POSIX`: Line ending for POSIX-compliant systems (`\n`).
* - `WIN32`: Line ending for Windows systems (`\r\n`).
*/
export declare const LINE_ENDINGS: {
POSIX: string;
WIN32: string;
};
/**
* An object representing supported platforms.
*
* - `DARWIN`: macOS platform identifier.
* - `LINUX`: Linux platform identifier.
* - `WIN32`: Windows platform identifier.
*/
export declare const SUPPORTED_PLATFORMS: {
DARWIN: string;
LINUX: string;
WIN32: string;
};
/**
* An object containing regular expressions for validating formats and units.
*
* - `FORMATS`: Matches supported text formats (`plain` or `html`), case-insensitive.
* - `UNITS`: Matches supported unit types (`paragraphs`, `sentences`, `words`), case-insensitive.
*/
export declare const REGEX: {
FORMATS: RegExp;
UNITS: RegExp;
};
export declare const UNIT_WORDS = "words";
export declare const UNIT_SENTENCES = "sentences";
export declare const UNIT_PARAGRAPHS = "paragraphs";
export declare const UNITS: string[];
export type LoremUnit = 'words' | 'sentences' | 'paragraphs';
declare const _default: {
FORMAT_HTML: string;
FORMAT_PLAIN: string;
FORMATS: string[];
LINE_ENDINGS: {
POSIX: string;
WIN32: string;
};
SUPPORTED_PLATFORMS: {
DARWIN: string;
LINUX: string;
WIN32: string;
};
REGEX: {
FORMATS: RegExp;
UNITS: RegExp;
};
UNIT_WORDS: string;
UNIT_SENTENCES: string;
UNIT_PARAGRAPHS: string;
UNITS: string[];
};
export default _default;