{"id":20144215,"url":"https://github.com/quansitech/progressive-image","last_synced_at":"2026-06-05T06:31:25.470Z","repository":{"id":52557507,"uuid":"359140182","full_name":"quansitech/progressive-image","owner":"quansitech","description":"渐进性加载图片插件","archived":false,"fork":false,"pushed_at":"2021-04-26T05:55:27.000Z","size":3,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-02T23:44:08.508Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/quansitech.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}},"created_at":"2021-04-18T12:44:03.000Z","updated_at":"2024-05-31T02:47:02.000Z","dependencies_parsed_at":"2022-08-21T03:40:58.593Z","dependency_job_id":null,"html_url":"https://github.com/quansitech/progressive-image","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/quansitech/progressive-image","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quansitech%2Fprogressive-image","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quansitech%2Fprogressive-image/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quansitech%2Fprogressive-image/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quansitech%2Fprogressive-image/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/quansitech","download_url":"https://codeload.github.com/quansitech/progressive-image/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quansitech%2Fprogressive-image/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33932048,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-05T02:00:06.157Z","response_time":120,"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":[],"created_at":"2024-11-13T22:09:16.229Z","updated_at":"2026-06-05T06:31:25.448Z","avatar_url":"https://github.com/quansitech.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 渐进式图片加载\n\n1. 先通过加载小图并模糊化提高用户体验，最后再加载高清图替换掉小图\n2. 高清图的加载替换会延迟进行，只有窗口滚动到图片的位置才会触发高清图的加载替换。\n3. 支持img标签和div background-image的渐进式加载\n\n## 用法\n```javascript\n\u003clink href=\"/progressive-image.css\" rel=\"stylesheet\"\u003e\n\u003cscript src=\"/progressive-image-min.js\"\u003e\u003c/script\u003e\n```\n\n需要使用渐进式加载的img标签\n```javascript\n//data-src 放需要加载的高清图\n//src 放模糊小图\n//class 必须加上 qs-progressive-image 插件会自动寻找有该类的标签进行渐进图片处理\n\u003cimg class=\"qs-progressive-image\" data-src=\"./1920x640.jpg\" src=\"./192x64.jpg\" alt=\"\"\u003e\n```\n\ndiv 背景图的用法\n```javascript\n//data-src 放需要加载的高清图\n//background-image url 放模糊小图\n//class 必须加上 qs-progressive-image 插件会自动寻找有该类的标签进行渐进图片处理\n\u003cdiv class=\"qs-progressive-image\" data-src=\"./1920x640.jpg\" style=\"background-image: url(./192x64.jpg);\" alt=\"\"\u003e\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquansitech%2Fprogressive-image","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fquansitech%2Fprogressive-image","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquansitech%2Fprogressive-image/lists"}