{"id":17082295,"url":"https://github.com/ko1ebayev/ngx-func-pipe","last_synced_at":"2025-05-13T11:32:37.975Z","repository":{"id":254920465,"uuid":"847959231","full_name":"ko1ebayev/ngx-func-pipe","owner":"ko1ebayev","description":"Angular typed pipe for efficient function calls in templates","archived":false,"fork":false,"pushed_at":"2024-10-08T09:33:50.000Z","size":175,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-22T05:31:40.403Z","etag":null,"topics":["angular","change-detection","pipe","templates"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/ngx-func-pipe","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ko1ebayev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-08-26T21:50:58.000Z","updated_at":"2024-10-25T19:05:13.000Z","dependencies_parsed_at":null,"dependency_job_id":"4be46a06-0ba1-447b-b7cc-5f27b2d6b465","html_url":"https://github.com/ko1ebayev/ngx-func-pipe","commit_stats":null,"previous_names":["ko1ebayev/ngx-func-pipe"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ko1ebayev%2Fngx-func-pipe","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ko1ebayev%2Fngx-func-pipe/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ko1ebayev%2Fngx-func-pipe/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ko1ebayev%2Fngx-func-pipe/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ko1ebayev","download_url":"https://codeload.github.com/ko1ebayev/ngx-func-pipe/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253933105,"owners_count":21986519,"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":["angular","change-detection","pipe","templates"],"created_at":"2024-10-14T13:00:24.748Z","updated_at":"2025-05-13T11:32:37.940Z","avatar_url":"https://github.com/ko1ebayev.png","language":"TypeScript","funding_links":[],"categories":["Recently Updated","Third Party Components"],"sub_categories":["[Oct 13, 2024](/content/2024/10/13/README.md)","Pipes"],"readme":"# NgxFuncPipe\n\nNgxFuncPipe is a simple and lightweight Angular pipe that allows you to call a function directly from your Angular templates. This utility is particularly useful when you need to invoke a function with arguments in your Angular templates.  \n\n### Features\n- Standalone Pipe: The NgxFuncPipe is a standalone Angular pipe, meaning it can be used without being declared in an Angular module.\n- Function Invocation in Templates: It allows you to invoke a function directly from your Angular templates with the required arguments.\n- Type-safe Templates: Full support for Angular's type-safe templates, ensuring that function types and arguments are reflected in the template.\n- Pure Pipe: The pipe is pure, meaning it only re-evaluates when its input values change, providing performance benefits.\n\n### Installation\nYou can install this library using npm or yarn:\nnpm install ngx-func-pipe\nyarn add ngx-func-pipe\n\n### Type-safe Template Usage\nSince Angular's templates are now type-safe, the function and its argument types will be reflected in the template, giving you full IntelliSense support:  \n\n```\nimport { Component } from '@angular/core';\nimport { NgxFuncPipe } from 'ngx-func-pipe';\n\n@Component({\n  selector: 'app-math',\n  template: `\n    \u003cdiv\u003e\n      \u003c!-- The type of foo and bar will be reflected in the template --\u003e\n      \u003cp\u003eSum: {{ foo | ngxFunc: 5: 10 }}\u003c/p\u003e\n      @if ((bar | ngxFunc: 'str': 1); as result) {\n        {{ result }}\n      }\n    \u003c/div\u003e\n  `,\n  standalone: true,\n  imports: [NgxFuncPipe]\n})\nexport class MathComponent {\n  foo(arg1: number, arg2: number): number {\n    return arg1 + arg2;\n  }\n\n  bar(arg1: string, arg2: number): boolean {\n    return arg1 \u0026\u0026 arg2;\n  }\n}\n```  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fko1ebayev%2Fngx-func-pipe","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fko1ebayev%2Fngx-func-pipe","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fko1ebayev%2Fngx-func-pipe/lists"}