{"id":23789938,"url":"https://github.com/blackglory/parse-favicon","last_synced_at":"2025-09-08T18:33:02.166Z","repository":{"id":44965042,"uuid":"74185731","full_name":"BlackGlory/parse-favicon","owner":"BlackGlory","description":"🌳 Parse HTML to get icon information","archived":false,"fork":false,"pushed_at":"2024-12-23T11:02:35.000Z","size":1454,"stargazers_count":56,"open_issues_count":2,"forks_count":7,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-08-28T01:49:24.452Z","etag":null,"topics":["library","nodejs","npm-package","typescript"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/parse-favicon","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/BlackGlory.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":"2016-11-19T03:58:28.000Z","updated_at":"2025-04-28T03:11:02.000Z","dependencies_parsed_at":"2023-12-20T18:29:18.234Z","dependency_job_id":"7a52b4f2-43d7-4cab-bdba-0972765ad42e","html_url":"https://github.com/BlackGlory/parse-favicon","commit_stats":{"total_commits":152,"total_committers":3,"mean_commits":"50.666666666666664","dds":0.05921052631578949,"last_synced_commit":"411731bed43dfbc9c83aec933d93be3e90a3d278"},"previous_names":[],"tags_count":51,"template":false,"template_full_name":null,"purl":"pkg:github/BlackGlory/parse-favicon","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackGlory%2Fparse-favicon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackGlory%2Fparse-favicon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackGlory%2Fparse-favicon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackGlory%2Fparse-favicon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BlackGlory","download_url":"https://codeload.github.com/BlackGlory/parse-favicon/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackGlory%2Fparse-favicon/sbom","scorecard":{"id":22522,"data":{"date":"2025-08-11","repo":{"name":"github.com/BlackGlory/parse-favicon","commit":"73a1e1246b1d7afce4709789e77783c7753ea236"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.8,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/nodejs.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 1 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/nodejs.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/BlackGlory/parse-favicon/nodejs.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/nodejs.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/BlackGlory/parse-favicon/nodejs.yml/master?enable=pin","Warn: npmCommand not pinned by hash: .github/workflows/nodejs.yml:21","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 npmCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Vulnerabilities","score":3,"reason":"7 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-14T17:08:06.618Z","repository_id":44965042,"created_at":"2025-08-14T17:08:06.619Z","updated_at":"2025-08-14T17:08:06.619Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274229373,"owners_count":25245188,"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","status":"online","status_checked_at":"2025-09-08T02:00:09.813Z","response_time":121,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["library","nodejs","npm-package","typescript"],"created_at":"2025-01-01T17:17:44.036Z","updated_at":"2025-09-08T18:33:02.140Z","avatar_url":"https://github.com/BlackGlory.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# parse-favicon\nParse HTML to get icon information.\n\n## Install\n```sh\nnpm install --save parse-favicon\n# or\nyarn add parse-favicon\n```\n\n## Usage\n```js\nimport { parseFavicon } from 'parse-favicon'\n\nconst pageURL = 'https://github.com'\n\nparseFavicon(pageURL, fetchText, fetchBuffer)\n  .subscribe(icon =\u003e console.log(icon))\n\nfunction fetchText(url: string): Promise\u003cstring\u003e {\n  return fetch(url)\n    .then(res =\u003e res.text())\n}\n\nfunction fetchBuffer(url: string): Promise\u003cArrayBuffer\u003e {\n  return fetch(url)\n    .then(res =\u003e res.arrayBuffer())\n}\n```\n\n## API\n### parseFavicon\n```ts\ntype TextFetcher = (url: string) =\u003e Awaitable\u003cstring\u003e // string | PromiseLike\u003cstring\u003e\ntype BufferFetcher = (url: string) =\u003e Awaitable\u003cArrayBuffer\u003e // ArrayBuffer | PromiseLike\u003cArrayBuffer\u003e\n\ninterface IIcon {\n  url: string\n  reference: string\n  type: null | string\n  size: null | 'any' | ISize | ISize[]\n}\n\ninterface ISize {\n  width: number\n  height: number\n}\n\nfunction parseFavicon(\n  pageURL: string\n, textFetcher: TextFetcher\n, bufferFetcher?: BufferFetcher\n): Observable\u003cIIcon\u003e\n```\n\n`parseFavicon` accepts `textFetcher` and `bufferFetcher` for further fetching requests when parsing icons, `bufferFetcher` is optional.\nIf you need actual icon sizes and type, should provide `bufferFetcher`.\n\nReferences related to `textFetcher`:\n- `\u003cmeta name=\"msapplication-config\" content=\"path/to/ieconfig.xml\"\u003e`\n- `\u003clink rel=\"manifest\" href=\"path/to/manifest.webmanifest\"\u003e`\n\nReferences related to `bufferFetcher`:\n- `/favicon.ico`\n- `/apple-touch-icon-57x57-precomposed.png`\n- `/apple-touch-icon-57x57.png`\n- `/apple-touch-icon-72x72-precomposed.png`\n- `/apple-touch-icon-72x72.png`\n- `/apple-touch-icon-114x114-precomposed.png`\n- `/apple-touch-icon-114x114.png`\n- `/apple-touch-icon-120x120-precomposed.png`\n- `/apple-touch-icon-120x120.png`\n- `/apple-touch-icon-144x144-precomposed.png`\n- `/apple-touch-icon-144x144.png`\n- `/apple-touch-icon-152x152-precomposed.png`\n- `/apple-touch-icon-152x152.png`\n- `/apple-touch-icon-180x180-precomposed.png`\n- `/apple-touch-icon-180x180.png`\n- `/apple-touch-icon-precomposed.png`\n- `/apple-touch-icon.png`\n\n## Supported references\n- `\u003clink rel=\"icon\" href=\"path/to/icon.png\"\u003e`\n- `\u003clink rel=\"shortcut icon\" href=\"path/to/icon.ico\"\u003e`\n- `\u003clink rel=\"apple-touch-icon\" href=\"path/to/icon.png\"\u003e`\n- `\u003clink rel=\"apple-touch-icon-precomposed\" href=\"path/to/icon.png\"\u003e`\n- `\u003clink rel=\"manifest\" href=\"path/to/manifest.webmanifest\"\u003e`\n- `\u003clink rel=\"fluid-icon\" href=\"path/to/icon.png\"\u003e`\n- `\u003clink rel=\"mask-icon\" href=\"path/to/icon.svg\"\u003e`\n- `\u003cmeta name=\"msapplication-TileImage\" content=\"path/to/icon.png\"\u003e`\n- `\u003cmeta name=\"msapplication-config\" content=\"path/to/ieconfig.xml\"\u003e`\n- `\u003cmeta name=\"msapplication-square70x70logo\" content=\"path/to/icon.png\"\u003e`\n- `\u003cmeta name=\"msapplication-square150x150logo\" content=\"path/to/icon.png\"\u003e`\n- `\u003cmeta name=\"msapplication-square310x310logo\" content=\"path/to/icon.png\"\u003e`\n- `\u003cmeta name=\"msapplication-wide310x150logo\" content=\"path/to/icon.png\"\u003e`\n- `/favicon.ico`\n- `/apple-touch-icon-57x57-precomposed.png`\n- `/apple-touch-icon-57x57.png`\n- `/apple-touch-icon-72x72-precomposed.png`\n- `/apple-touch-icon-72x72.png`\n- `/apple-touch-icon-114x114-precomposed.png`\n- `/apple-touch-icon-114x114.png`\n- `/apple-touch-icon-120x120-precomposed.png`\n- `/apple-touch-icon-120x120.png`\n- `/apple-touch-icon-144x144-precomposed.png`\n- `/apple-touch-icon-144x144.png`\n- `/apple-touch-icon-152x152-precomposed.png`\n- `/apple-touch-icon-152x152.png`\n- `/apple-touch-icon-180x180-precomposed.png`\n- `/apple-touch-icon-180x180.png`\n- `/apple-touch-icon-precomposed.png`\n- `/apple-touch-icon.png`\n\n## Related projects\n- [favicon-detector](https://github.com/BlackGlory/favicon-detector)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblackglory%2Fparse-favicon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fblackglory%2Fparse-favicon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblackglory%2Fparse-favicon/lists"}