MCPcopy Index your code
hub / github.com/Linen-dev/linen.dev / pad

Function pad

packages/utilities/src/string.ts:38–43  ·  view source on GitHub ↗
(string: string, length: number)

Source from the content-addressed store, hash-verified

36}
37
38export function pad(string: string, length: number) {
39 if (string.length < length) {
40 return `0`.repeat(length - string.length) + string;
41 }
42 return string;
43}
44
45export const slugify = (message: string) => {
46 let slug = message

Callers 2

string.spec.tsFile · 0.90
createLinenCommunityFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected