{"id":32434967,"url":"https://github.com/dperrymorrow/electron-css-reload","last_synced_at":"2026-03-15T01:55:27.295Z","repository":{"id":57221558,"uuid":"67838956","full_name":"dperrymorrow/electron-css-reload","owner":"dperrymorrow","description":"force reload CSS on change in your electron app","archived":false,"fork":false,"pushed_at":"2022-09-13T19:38:51.000Z","size":12,"stargazers_count":4,"open_issues_count":3,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-10-25T22:05:14.217Z","etag":null,"topics":["css-changes","electron","force-reload-css"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/dperrymorrow.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-09-09T23:26:37.000Z","updated_at":"2022-09-13T19:38:56.000Z","dependencies_parsed_at":"2022-08-29T04:10:07.452Z","dependency_job_id":null,"html_url":"https://github.com/dperrymorrow/electron-css-reload","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dperrymorrow/electron-css-reload","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dperrymorrow%2Felectron-css-reload","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dperrymorrow%2Felectron-css-reload/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dperrymorrow%2Felectron-css-reload/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dperrymorrow%2Felectron-css-reload/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dperrymorrow","download_url":"https://codeload.github.com/dperrymorrow/electron-css-reload/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dperrymorrow%2Felectron-css-reload/sbom","scorecard":{"id":354317,"data":{"date":"2025-08-11","repo":{"name":"github.com/dperrymorrow/electron-css-reload","commit":"11fbddf5e624476bbca8777f7915c9209e40fbbb"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.2,"checks":[{"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":"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":"Code-Review","score":1,"reason":"Found 2/17 approved changesets -- score normalized to 1","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":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"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":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"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":"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":"Dangerous-Workflow","score":-1,"reason":"no workflows found","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":"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":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"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":"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 '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":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 4 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"}}]},"last_synced_at":"2025-08-18T09:10:12.145Z","repository_id":57221558,"created_at":"2025-08-18T09:10:12.146Z","updated_at":"2025-08-18T09:10:12.146Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281026382,"owners_count":26431785,"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-25T02:00:06.499Z","response_time":81,"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":["css-changes","electron","force-reload-css"],"created_at":"2025-10-25T22:04:44.828Z","updated_at":"2025-10-25T22:08:20.070Z","avatar_url":"https://github.com/dperrymorrow.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# electron-css-reload\nforce reload CSS on change in your electron App\n\nReload style sheets on your page on change in your electron App.\n\n## Usage\n\n```javascript\nconst reload = require('electron-css-reload');\n```\n\nThen, open your devtools window and invoke the method to begin watching for CSS changes in your Electron app.\n\n```javascript\n// from your console\nreload()\n```\n\nOr, when in dev mode, invoke the method from the start.\n\n```javascript\nrequire('electron-css-reload')();\n```\n\nYou can also pass in the frequency you would like it to look for chanages in your css\n\u003e defaults to 1000 (1 second)\n\n```javascript\nreload(250)\n```\n\nThat't it, enjoy not restarting your Electron app every time you wanna see a CSS change.\n\n## Also watching dependencies of the css file\n\nYou can also watch dependencies of the CSS file you have loaded. This is helpful for situations like including other CSS files into your main file.\n\n\n```html\n\u003clink rel=\"stylesheet\" type=\"text/css\" href=\"../../frontend/styles/index.css\" data-source=\"fonts.css,animations.css\"/\u003e\n```\n\n\u003e the paths in data-sources should be relative to the file path of the href\n\n## Watching inline-styles\n\nYou can also watch inline styles for changes by giving an id, and a ```data-source```.\n\n\n\u003e data-source path should be top down from your electron application.\n\n```html\n\u003cstyle type=\"text/css\" id=\"test-id\" data-source=\"/app/pages/main/index.html\"\u003e\n  body {\n    background-color: red;\n  }\n\u003c/style\u003e\n```\n\n## How does it work?\n\nSince Electron has access to the file system, it uses ```fs.watchFile``` to watch for changes to the files loaded via ```\u003clink\u003e``` tags on the page.\n\nWhen a change event fires, a ```?nocache={timestamp}``` is added to the href on the stylesheet link on the page.\nThis forces the browser to reload the sheet as it sees it as a new URL.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdperrymorrow%2Felectron-css-reload","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdperrymorrow%2Felectron-css-reload","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdperrymorrow%2Felectron-css-reload/lists"}