UNPKG

@dazejs/framework

Version:

Daze.js - A powerful web framework for Node.js

53 lines (52 loc) 3.16 kB
export declare class Str { static formatPrefix(prefix?: string): string; static decodeBASE64(str: string): any; static encodeBASE64(body: any): string; static aesEncrypt(val: string, key: string, iv?: string | null): string; static slugify: (str: string) => string; static numberFormat: (number: number, dec?: number | undefined, dsep?: string | undefined, tsep?: string | undefined) => string; static capitalize: (str: string) => string; static decapitalize: (str: string) => string; static titleize: (str: string) => string; static camelize: (str: string, decapitalize?: boolean | undefined) => string; static swapCase: (str: string) => string; static chop: (str: string, step: number) => any[]; static chars: (str: string) => any[]; static include: (str: string, needle: string) => boolean; static count: (str: string, substr: string) => number; static escapeHTML: (str: string) => string; static unescapeHTML: (str: string) => string; static insert: (str: string, i: number, substr: string) => string; static isBlank: (str: string) => boolean; static join: (separator: string, ...args: string[]) => string; static lines: (str: string) => any[]; static words: { (str: string): string[]; (str: string, delimiter: string): string[]; (str: string, delimiter: RegExp): string[]; }; static reverse: (str: string) => string; static startsWith: (str: string, starts: string) => boolean; static endsWith: (value: string, starts: string) => boolean; static classify: (str: string) => string; static underscored: (str: string) => string; static trim: (str: string, characters?: string | undefined) => string; static truncate: (str: string, length: number, truncateStr?: string | undefined) => string; static prune: (str: string, length: number, pruneStr?: string | undefined) => string; static sprintf: (format: string, ...args: any[]) => string; static pad: (str: string, length: number, padStr?: string | undefined, type?: string | undefined) => string; static lpad: (str: string, length: number, padStr?: string | undefined) => string; static rpad: (str: string, length: number, padStr?: string | undefined) => string; static lrpad: (str: string, length: number, padStr?: string | undefined) => string; static toNumber: (str: string, decimals?: number | undefined) => number; static repeat: (value: string, count: number, separator?: string | undefined) => string; static surround: (str: string, wrapper: string) => string; static quote: (str: string, quoteChar?: string | undefined) => string; static unquote: (str: string, quoteChar?: string | undefined) => string; static toBoolean: (str: string, trueValues?: any[] | undefined, falseValues?: any[] | undefined) => boolean; static strRight: (str: string, sep: string) => string; static strRightBack: (str: string, sep: string) => string; static strLeft: (str: string, sep: string) => string; static strLeftBack: (str: string, sep: string) => string; static stripTags: (str: string) => string; }