{"id":18777511,"url":"https://github.com/onify/flow-script-functions","last_synced_at":"2026-05-18T11:05:59.378Z","repository":{"id":227357495,"uuid":"753015886","full_name":"onify/flow-script-functions","owner":"onify","description":"Flow Script Functions - A set of script functions to use in Onify Flow","archived":false,"fork":false,"pushed_at":"2024-05-06T10:37:28.000Z","size":26,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-16T17:57:04.766Z","etag":null,"topics":["nodejs","onify","onify-functions"],"latest_commit_sha":null,"homepage":"https://onify.co","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/onify.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-02-05T09:57:33.000Z","updated_at":"2024-05-03T16:35:55.000Z","dependencies_parsed_at":"2024-05-06T11:43:56.692Z","dependency_job_id":null,"html_url":"https://github.com/onify/flow-script-functions","commit_stats":{"total_commits":29,"total_committers":2,"mean_commits":14.5,"dds":"0.31034482758620685","last_synced_commit":"6afef37a193c3ace4f0c122b102b19fee0050beb"},"previous_names":["onify/script-functions","onify/flow-script-functions"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/onify%2Fflow-script-functions","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/onify%2Fflow-script-functions/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/onify%2Fflow-script-functions/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/onify%2Fflow-script-functions/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/onify","download_url":"https://codeload.github.com/onify/flow-script-functions/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239687790,"owners_count":19680789,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["nodejs","onify","onify-functions"],"created_at":"2024-11-07T20:11:23.382Z","updated_at":"2026-05-18T11:05:54.329Z","avatar_url":"https://github.com/onify.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Onify Script Functions\n\n[![Build latest](https://github.com/onify/flow-script-functions/actions/workflows/build.yaml/badge.svg)](https://github.com/onify/flow-script-functions/actions/workflows/build.yaml)\n\nThis library provides various functions designed for Onify Flow that can also be used in Node.js applications.\n\nThe functions available are as follows:\n\n- [generate UUID](#generate-uuid)\n- [slugify](#slugify)\n- [validate email](#validate-email)\n\n## Onify Flow\nUse `functions.*` to access the functions present in this library.\n\n```js\nconst result = functions.slugify('sample onify');\nconsole.log(result); // output: sample-onify\n```\n\n## Installation\n\n```\nnpm install @onify/flow-script-functions\n```\n\n## Usage\n\n### Import the library:\n\n##### Javascript\n\n```js\nconst functions = require('@onify/flow-script-functions');\n```\n\n##### Typescript\n\n```ts\n// import all functions\nimport * as functions from '@onify/flow-script-functions';\n// or\n// import specific functions\nimport { slugify } from '@onify/flow-script-functions';\n```\n\n### Use the functions:\n\n```ts\n// example usage of `slugify` function\nlet output = functions.slugify('Hello World!');\n// or\n// when using specific imports in TypeScript\noutput = slugify('Hello World!');\n```\n\n## Generate UUID\n\nCreates a GUID string using `crypto`\n\n### Syntax\n\n```\ngenerateUuid(): string\n```\n\n### Return value\n\nGUID string with the format `${string}-${string}-${string}-${string}-${string}`\n\n### Example\n\n```ts\nimport { generateUuid } from '@onify/flow-script-functions';\n\n// ...\nconst id = generateUuid(); // generates random GUID\nconsole.log(id); // sample output: \"55d03475-45fe-4415-81d7-8cd052081fe1\"\n```\n\n## Slugify\n\nTransforms string to kebab case\n\n### Syntax\n\n```\nslugify(text: string): string\n```\n\n### Parameters\n\n| Name | Type     | Description                   |\n| :--- | :------- | ----------------------------- |\n| text | `string` | the string value to transform |\n\n### Return value\n\n`kebab-case` of the input\n\n### Example\n\n```ts\nimport { slugify } from '@onify/flow-script-functions';\n\n// ...\nconst transformedText = slugify('Hello World!');\nconsole.log(transformedText); // output: \"hello-world\"\n```\n\n## Validate Email\n\nChecks if string is a valid email format\n\n### Syntax\n\n```\nvalidateEmail(email: string): boolean\n```\n\n### Parameters\n\n| Name  | Type     | Description        |\n| :---- | :------- | ------------------ |\n| email | `string` | string to validate |\n\n### Return value\n\n`true` if input is a valid email format, otherwise `false`\n\n### Example\n\n```ts\nimport { validateEmail } from '@onify/flow-script-functions';\n\n// ...\nconst isValid = slugify('sample@onify.co');\nconsole.log(isValid); // output: true\n```\n\n## Release new version and publish to npm\n\n1. Update `version` in `package.json`\n2. Update `CHANGELOG.md`\n3. Commit and push the changes\n4. Run `npm run release`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fonify%2Fflow-script-functions","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fonify%2Fflow-script-functions","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fonify%2Fflow-script-functions/lists"}