{"id":13808951,"url":"https://github.com/angular-experts-io/ng-parsel","last_synced_at":"2026-01-05T15:14:33.621Z","repository":{"id":63911618,"uuid":"571528880","full_name":"angular-experts-io/ng-parsel","owner":"angular-experts-io","description":"Parse your Angular code base to JSON abstraction - Great for displaying APIs and running custom analysis","archived":false,"fork":false,"pushed_at":"2024-03-14T16:37:34.000Z","size":10094,"stargazers_count":9,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-03-15T08:55:49.819Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/angular-experts-io.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2022-11-28T10:31:39.000Z","updated_at":"2024-04-30T14:47:49.569Z","dependencies_parsed_at":"2024-04-30T14:47:32.912Z","dependency_job_id":"aa36618f-a19f-48b8-82f7-9d0f8012fe6c","html_url":"https://github.com/angular-experts-io/ng-parsel","commit_stats":{"total_commits":92,"total_committers":3,"mean_commits":"30.666666666666668","dds":"0.11956521739130432","last_synced_commit":"39889cb47b4c9057143731c6145eca32450c0ccf"},"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angular-experts-io%2Fng-parsel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angular-experts-io%2Fng-parsel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angular-experts-io%2Fng-parsel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angular-experts-io%2Fng-parsel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/angular-experts-io","download_url":"https://codeload.github.com/angular-experts-io/ng-parsel/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225273295,"owners_count":17448083,"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":[],"created_at":"2024-08-04T01:01:55.853Z","updated_at":"2026-01-05T15:14:33.567Z","avatar_url":"https://github.com/angular-experts-io.png","language":"TypeScript","funding_links":[],"categories":["Development Utilities"],"sub_categories":["Code Analysis"],"readme":"# ng-parsel\n\n\u003c!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section --\u003e\n\n[![All Contributors](https://img.shields.io/badge/all_contributors-4-orange.svg?style=flat-square)](#contributors-)\n\n\u003c!-- ALL-CONTRIBUTORS-BADGE:END --\u003e\n\n[![Coverage Status](https://coveralls.io/repos/github/angular-experts-io/ng-parsel/badge.svg?branch=main)](https://coveralls.io/github/angular-experts-io/ng-parsel?branch=main)\n\n\u003e Convert your Angular components to JSON\n\n\u003cdiv style=\"display: flex; justify-content: center\"\u003e\n\u003cimg src=\"https://github.com/angular-experts-io/ng-parsel/blob/main/docs/logo.png?raw=true\" style=\"width: 250px\"\u003e\n\u003c/div\u003e\n\n\u003c!-- START doctoc generated TOC please keep comment here to allow auto update --\u003e\n\u003c!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --\u003e\n\n- [What is this module about](#what-is-this-module-about)\n- [Getting started](#getting-started)\n  - [Install](#install)\n  - [Init configuration](#init-configuration)\n- [Commands](#commands)\n  - [Parse](#parse)\n    - [Parse script](#parse-script)\n    - [NPX](#npx)\n    - [Configuration](#configuration)\n  - [Stats](#stats)\n    - [Stats script](#stats-script)\n    - [NPX](#npx-1)\n- [Types](#types)\n- [Type detection](#type-detection)\n- [Outputs](#outputs)\n- [Contributors](#contributors)\n\n\u003c!-- END doctoc generated TOC please keep comment here to allow auto update --\u003e\n\n## What is this module about\n\nThis module extracts the most important information of your Angular code base and converts it into JSON. Having the most\nimportant parts of your Angular code base as JSON can be very useful to perform custom analysis or to display APIs.\nDisplaying APIs is especially useful for library authors that want to illustrate their library in a component showcase.\n\n## Getting started\n\n### Install\n\nInstall ng-parsel as a dev dependency in your repository.\n\n```bash\nnpm i -D @angular-experts/ng-parsel\n```\n\n### Init configuration\n\nOnce installed you can use npx to create an initial configuration for ng-parsel.\n\n```bash\nnpx @angular-experts/ng-parsel init\n```\n\nRunning this command will create a `.parselrc.json` configuration file in the root of your repository. Check the initial\nconfiguration and adjust if needed. The configuration properties and their meaning are explained in\nthe [configuration section](#configuration).\n\n## Commands\n\n### Parse\n\nTo parse the code base you can either create a parse script in your `package.json`which calls `ng-parsel` or you can use\nnpx.\n\n#### Parse script\n\nAdd the following script to your `package.json`.\n\n```json\n\"parse\": \"@angular-experts/ng-parsel parse\"\n```\n\nOnce added, you can open up a terminal and run the following command.\n\n```bash\nnpm run parse\n```\n\n#### NPX\n\nTo parse your code base with npx you can run the follwoing command inisde a terminal of your choice.\n\n```bash\nnpx @angular-experts/ng-parsel parse\n```\n\n#### Configuration\n\nng-parsel offers the following configurations.\n\n| Property        | Default value | Description                                                                                                                                                                                                                                                                |\n| --------------- | ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| src             | 'src'         | Glob to query all the src files that should be parsed                                                                                                                                                                                                                      |\n| out             | 'ng-parsel'   | Output directory                                                                                                                                                                                                                                                           |\n| parseComponents | true          | If set to `true` ng-parsel will parse Angular Components and include them in the output.                                                                                                                                                                                   |\n| parseServices   | true          | If set to `true` ng-parsel will parse Angular Services and include them in the output.                                                                                                                                                                                     |\n| parsePipes      | true          | If set to `true` ng-parsel will parse Angular Pipes and include them in the output.                                                                                                                                                                                        |\n| parseDirectives | true          | If set to `true` ng-parsel will parse Angular Directives and include them in the output.                                                                                                                                                                                   |\n| parseModules    | true          | If set to true ng-parsel will parse Angular Modules and include them in the output.                                                                                                                                                                                        |\n| parseHarnesses  | true          | If set to true ng-parsel will parse Harness test files (all files ending with `.harness.ts`) and include them in the output.                                                                                                                                               |\n| parseValidators | true          | If set to true ng-parsel will parse Validators (all files ending with `.validator.ts`) and include them in the output.                                                                                                                                                     |\n| parseSpecs      | true          | If set to true ng-parsel will parse testing files (all files ending with `.spec.ts`) and include them in the output.                                                                                                                                                       |\n| singleFile      | true          | If set to to `true` the output will be written to a `ng-parsel.json` file in the output directory. If set to false, ng-parsel will generate multiple output files, one for each `componentType`. (Find out more on component types in the [next section](#component-type)) |\n\n### Stats\n\nThe stats command is a command that gives you a quick overview of your Angular application. It shows you how many components, services, pipes, directives, modules, harnesses and specs you have in your application. Furthermore, it shows you interesting insights, like how many are standanlone and how many are part of a module.\nTo run the stats command you can either create a stats script in your `package.json`which calls `ng-parsel` or you can use `npx`;\n\n#### Stats script\n\n```json\n\"stats\": \"@angular-experts/ng-parsel stats\"\n```\n\n#### NPX\n\n```bash\nnpx @angular-experts/ng-parsel stats\n```\n\n## Types\n\nCurrently ng-parsel classifies each file into one of the following `NgParselOutputType`.\n\n- Component\n- Service\n- Pipes\n- Modules\n- Directives\n- Harnesses\n- Specs\n- Unknown\n\nUnknown files will not be parsed. If you need support for additional types please raise an issue or open a PR.\n\n## Type detection\n\nHarnesses, Specs and Validators are detected by the filename. Everything that ends with `.spec` will be classified\nas a spec file. Everything that ends with `.harness` will be classified as a harness file. Everything that ends with\n`.validator` will be classified as a validator file.\n\nAll other types are detected by their Angular decorators.\n\n## Outputs\n\nSingle outputs will be written to a `ng-parsel.json` file in the output directory.\nIf `singleFile` is set to `false` ng-parsel will generate multiple output files, one for each `componentType`. (Find out more on [component types](#component-type))\n\n## Contributors\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --\u003e\n\u003c!-- prettier-ignore-start --\u003e\n\u003c!-- markdownlint-disable --\u003e\n\u003ctable\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://medium.com/@kevinkreuzer\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/5468954?v=4?s=100\" width=\"100px;\" alt=\"Kevin Kreuzer\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eKevin Kreuzer\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/angular-experts-io/ng-parsel/commits?author=kreuzerk\" title=\"Code\"\u003e💻\u003c/a\u003e \u003ca href=\"https://github.com/angular-experts-io/ng-parsel/issues?q=author%3Akreuzerk\" title=\"Bug reports\"\u003e🐛\u003c/a\u003e \u003ca href=\"#content-kreuzerk\" title=\"Content\"\u003e🖋\u003c/a\u003e \u003ca href=\"https://github.com/angular-experts-io/ng-parsel/commits?author=kreuzerk\" title=\"Documentation\"\u003e📖\u003c/a\u003e \u003ca href=\"#design-kreuzerk\" title=\"Design\"\u003e🎨\u003c/a\u003e \u003ca href=\"#ideas-kreuzerk\" title=\"Ideas, Planning, \u0026 Feedback\"\u003e🤔\u003c/a\u003e \u003ca href=\"#maintenance-kreuzerk\" title=\"Maintenance\"\u003e🚧\u003c/a\u003e \u003ca href=\"#platform-kreuzerk\" title=\"Packaging/porting to new platform\"\u003e📦\u003c/a\u003e \u003ca href=\"#research-kreuzerk\" title=\"Research\"\u003e🔬\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://www.npmjs.com/~ngdaddy\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/81327266?v=4?s=100\" width=\"100px;\" alt=\"@NgDaddy\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003e@NgDaddy\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"#ideas-NgDaddy\" title=\"Ideas, Planning, \u0026 Feedback\"\u003e🤔\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://medium.com/@lilbeqiri\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/24731032?v=4?s=100\" width=\"100px;\" alt=\"Ilir Beqiri\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eIlir Beqiri\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/angular-experts-io/ng-parsel/commits?author=ilirbeqirii\" title=\"Code\"\u003e💻\u003c/a\u003e \u003ca href=\"https://github.com/angular-experts-io/ng-parsel/commits?author=ilirbeqirii\" title=\"Tests\"\u003e⚠️\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"http://quentin.monmert.pagesperso-orange.fr/\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/9989211?v=4?s=100\" width=\"100px;\" alt=\"Quentin\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eQuentin\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"#maintenance-qmonmert\" title=\"Maintenance\"\u003e🚧\u003c/a\u003e \u003ca href=\"https://github.com/angular-experts-io/ng-parsel/commits?author=qmonmert\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\n\u003c!-- markdownlint-restore --\u003e\n\u003c!-- prettier-ignore-end --\u003e\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:END --\u003e\n\u003c!-- prettier-ignore-start --\u003e\n\u003c!-- markdownlint-disable --\u003e\n\n\u003c!-- markdownlint-restore --\u003e\n\u003c!-- prettier-ignore-end --\u003e\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:END --\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangular-experts-io%2Fng-parsel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fangular-experts-io%2Fng-parsel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangular-experts-io%2Fng-parsel/lists"}