{"id":13803980,"url":"https://github.com/bezoerb/grunt-critical","last_synced_at":"2025-10-06T19:05:09.501Z","repository":{"id":18917604,"uuid":"22136504","full_name":"bezoerb/grunt-critical","owner":"bezoerb","description":"Grunt task to extract \u0026 inline critical-path CSS from HTML","archived":false,"fork":false,"pushed_at":"2025-07-21T23:11:13.000Z","size":1789,"stargazers_count":156,"open_issues_count":22,"forks_count":28,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-08-28T22:04:14.207Z","etag":null,"topics":["above-the-fold","critical-css","critical-path","grunt"],"latest_commit_sha":null,"homepage":null,"language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bezoerb.png","metadata":{"files":{"readme":"README.md","changelog":"History.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":"2014-07-23T07:34:12.000Z","updated_at":"2025-03-26T07:37:32.000Z","dependencies_parsed_at":"2023-02-18T03:16:28.829Z","dependency_job_id":null,"html_url":"https://github.com/bezoerb/grunt-critical","commit_stats":{"total_commits":169,"total_committers":9,"mean_commits":18.77777777777778,"dds":0.4319526627218935,"last_synced_commit":"661b05a9e9ec291231e0b38d7d14f2671d990b8b"},"previous_names":[],"tags_count":25,"template":false,"template_full_name":null,"purl":"pkg:github/bezoerb/grunt-critical","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezoerb%2Fgrunt-critical","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezoerb%2Fgrunt-critical/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezoerb%2Fgrunt-critical/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezoerb%2Fgrunt-critical/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bezoerb","download_url":"https://codeload.github.com/bezoerb/grunt-critical/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezoerb%2Fgrunt-critical/sbom","scorecard":{"id":235759,"data":{"date":"2025-08-11","repo":{"name":"github.com/bezoerb/grunt-critical","commit":"661b05a9e9ec291231e0b38d7d14f2671d990b8b"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.6,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 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":"Code-Review","score":0,"reason":"Found 0/4 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":"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":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/test.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":"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":"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":"Pinned-Dependencies","score":2,"reason":"dependency not pinned by hash detected -- score normalized to 2","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/bezoerb/grunt-critical/test.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/bezoerb/grunt-critical/test.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:30: update your workflow using https://app.stepsecurity.io/secureworkflow/bezoerb/grunt-critical/test.yml/main?enable=pin","Info:   0 out of   3 GitHub-owned GitHubAction dependencies pinned","Info:   1 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":"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":9,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Warn: project license file does not contain an FSF or OSI license."],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"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":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"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":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 27 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"16 existing vulnerabilities detected","details":["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-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-4q6p-r6v2-jvc5","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55","Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg","Warn: Project is vulnerable to: GHSA-76p7-773f-r4q5","Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p","Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7","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-17T05:42:18.504Z","repository_id":18917604,"created_at":"2025-08-17T05:42:18.504Z","updated_at":"2025-08-17T05:42:18.504Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278663361,"owners_count":26024388,"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-10-06T02:00:05.630Z","response_time":65,"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":["above-the-fold","critical-css","critical-path","grunt"],"created_at":"2024-08-04T01:00:39.832Z","updated_at":"2025-10-06T19:05:09.472Z","avatar_url":"https://github.com/bezoerb.png","language":"HTML","funding_links":[],"categories":["Grunt tasks"],"sub_categories":[],"readme":"# grunt-critical\n\nGrunt plugin to extract \u0026 inline critical-path CSS from HTML\n\n[![NPM version][npm-image]][npm-url]\n[![Build Status][ci-image]][ci-url]\n[![Dependency Status][depstat-image]][depstat-url]\n\n## Getting Started\n\nIf you haven't used [Grunt](https://gruntjs.com/) before, be sure to check out the [Getting Started](https://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](https://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:\n\n```shell\nnpm install grunt-critical --save-dev\n```\n\nOnce the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:\n\n```js\ngrunt.loadNpmTasks('grunt-critical');\n```\n\n## Critical task\n\n_Run this task with the `grunt critical` command._\n\nTask targets, files and options may be specified according to the grunt [Configuring tasks](https://gruntjs.com/configuring-tasks) guide.\n\nGenerate critical path css and inline it with [critical](https://github.com/addyosmani/critical).\n\n### Usage\n\nUse the `grunt-critical` task by specifying a target destination (file) for your critical CSS. Below this is `test/generated/critical.css`.\n\nAlong-side, specify the input HTML file you would like scanned as well as the width and height of the critical viewport.\nIn this case `test/fixture/index.html`.\n\n```js\ncritical: {\n    test: {\n        options: {\n            base: './',\n            css: [\n                'test/fixture/styles/main.css',\n                'test/fixture/styles/bootstrap.css'\n            ],\n            width: 320,\n            height: 70\n        },\n        src: 'test/fixture/index.html',\n        dest: 'test/generated/critical.css'\n    }\n}\n```\n\nIf the `dest` file is a stylesheet, the resulting critical-path css is saved to this file for later use.\nIf `dest` points to an Markup file (HTML, PHP, etc.) the resulting CSS gets inlined and the exiting stylesheets are\nwrapped in a javascript function to load them asynchronously as well as a `noscript` block for users with JavaScript disabled\n\n```js\ncritical: {\n    test: {\n        options: {\n            base: './',\n            css: [\n                'test/fixture/styles/main.css',\n                'test/fixture/styles/bootstrap.css'\n            ],\n            width: 320,\n            height: 70\n        },\n        src: 'test/fixture/index.html',\n        dest: 'test/generated/index-critical.html'\n    }\n}\n```\n\n## Options\n\nFor a full list of options see [critical](https://github.com/addyosmani/critical#options)\n\n## License\n\n(C) Ben Zörb 2014, released under an MIT license\n\n\n[npm-url]: https://npmjs.org/package/grunt-critical\n[npm-image]: https://badge.fury.io/js/grunt-critical.svg\n\n[ci-url]: https://github.com/bezoerb/grunt-critical/actions?workflow=Tests\n[ci-image]: https://github.com/bezoerb/grunt-critical/workflows/Tests/badge.svg\n\n[depstat-url]: https://david-dm.org/bezoerb/grunt-critical\n[depstat-image]: https://david-dm.org/bezoerb/grunt-critical.svg\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbezoerb%2Fgrunt-critical","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbezoerb%2Fgrunt-critical","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbezoerb%2Fgrunt-critical/lists"}