{"id":14957667,"url":"https://github.com/liu927971519/express-web","last_synced_at":"2026-01-19T22:32:07.481Z","repository":{"id":143878979,"uuid":"160362337","full_name":"liu927971519/express-web","owner":"liu927971519","description":"express搭建静态web服务器","archived":false,"fork":false,"pushed_at":"2019-08-17T02:57:59.000Z","size":34,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-08-09T05:55:51.492Z","etag":null,"topics":["express","gzip","node","server","web"],"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/liu927971519.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-12-04T13:32:44.000Z","updated_at":"2020-01-05T08:26:42.000Z","dependencies_parsed_at":"2023-06-02T14:45:24.275Z","dependency_job_id":null,"html_url":"https://github.com/liu927971519/express-web","commit_stats":null,"previous_names":["liu927971519/expresss-web"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/liu927971519/express-web","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liu927971519%2Fexpress-web","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liu927971519%2Fexpress-web/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liu927971519%2Fexpress-web/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liu927971519%2Fexpress-web/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/liu927971519","download_url":"https://codeload.github.com/liu927971519/express-web/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liu927971519%2Fexpress-web/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28587241,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-19T20:45:59.482Z","status":"ssl_error","status_checked_at":"2026-01-19T20:45:41.500Z","response_time":67,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["express","gzip","node","server","web"],"created_at":"2024-09-24T13:15:18.919Z","updated_at":"2026-01-19T22:32:07.467Z","avatar_url":"https://github.com/liu927971519.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# express-web 一个静态服务器\n\n![NPM version](https://img.shields.io/badge/express--static--web-v%200.0.17-green.svg)\n\n\u003e 在前端项目要发布测试与生产环境，一般情况都会将打包好资源文件，使用nginx或tomcat等方式\n进行本地验证，验证通过再进行线上部署。那有更便捷验证方式？就是express-web，详情使用请看\n下文。\n\n## 必要条件\n使用之前必须保证已经安装好 node \u003e= 8.10.0 与 npm \u003e= 6.1.0\n\n## 特性\n1. 支持自定义端口\n2. 支持gzip\n3. 支持缓存\n\n## 使用说明\n### npm安装使用\n```\n  1. npm i express-static-web cross-env --save-dev\n  2. 在package.json的script中添加\n     \"scripts\": {\n        \"preserver\": \"npm run build\",\n        \"server\": \"cross-env Port=3001 Open=true Folder=dist express-static-web dev\",\n     }\n  3. npm run server 启动\n\n  备注：\n        preserver: 在npm run server之前执行打包命令\n        Port: 端口号\n        Open: 是否自动打开浏览器\n        Folder: 打包之后文件夹名称\n```\n\n### 用于在服务器上部署前端项目\n```\n  1. 全局安装安装pm2： npm install -g  pm2\n  2. 克隆本项目： git clone https://github.com/liu927971519/expresss-web.git\n  3. 安装依赖 npm install\n  4. 将打包好的部署文件放在dist文件夹\n  5. 启动: npm run start 或 PORT=端口号 npm run start\n```\n\n### 若有使用上问题或bug，欢迎在Issues提出\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliu927971519%2Fexpress-web","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fliu927971519%2Fexpress-web","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliu927971519%2Fexpress-web/lists"}