{"id":15184556,"url":"https://github.com/easy-team/easywebpack-html","last_synced_at":"2025-03-30T04:30:52.264Z","repository":{"id":57218988,"uuid":"112085399","full_name":"easy-team/easywebpack-html","owner":"easy-team","description":"HTML静态多页面Webpack构建工程化解决方案","archived":false,"fork":false,"pushed_at":"2018-10-18T03:24:47.000Z","size":12,"stargazers_count":7,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-21T11:02:59.758Z","etag":null,"topics":["html","html-template","html-webpack-plugin","nunjucks","nunjucks-templates","webpack"],"latest_commit_sha":null,"homepage":"https://easyjs.cn","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/easy-team.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}},"created_at":"2017-11-26T13:37:07.000Z","updated_at":"2021-12-17T18:28:49.000Z","dependencies_parsed_at":"2022-08-29T02:11:52.180Z","dependency_job_id":null,"html_url":"https://github.com/easy-team/easywebpack-html","commit_stats":null,"previous_names":["hubcarl/easywebpack-html"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easy-team%2Feasywebpack-html","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easy-team%2Feasywebpack-html/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easy-team%2Feasywebpack-html/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easy-team%2Feasywebpack-html/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/easy-team","download_url":"https://codeload.github.com/easy-team/easywebpack-html/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246277352,"owners_count":20751548,"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","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":["html","html-template","html-webpack-plugin","nunjucks","nunjucks-templates","webpack"],"created_at":"2024-09-27T17:04:47.883Z","updated_at":"2025-03-30T04:30:51.948Z","avatar_url":"https://github.com/easy-team.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# easywebpack-html\n\n[![NPM version][npm-image]][npm-url]\n[![build status][travis-image]][travis-url]\n[![Test coverage][codecov-image]][codecov-url]\n[![David deps][david-image]][david-url]\n[![Known Vulnerabilities][snyk-image]][snyk-url]\n[![npm download][download-image]][download-url]\n\n[npm-image]: https://img.shields.io/npm/v/easywebpack-html.svg?style=flat-square\n[npm-url]: https://npmjs.org/package/easywebpack-html\n[travis-image]: https://img.shields.io/travis/hubcarl/easywebpack-html.svg?style=flat-square\n[travis-url]: https://travis-ci.org/hubcarl/easywebpack-html\n[codecov-image]: https://img.shields.io/codecov/c/github/hubcarl/easywebpack-html.svg?style=flat-square\n[codecov-url]: https://codecov.io/github/hubcarl/easywebpack-html?branch=master\n[david-image]: https://img.shields.io/david/hubcarl/easywebpack-html.svg?style=flat-square\n[david-url]: https://david-dm.org/hubcarl/easywebpack-html\n[snyk-image]: https://snyk.io/test/npm/easywebpack-html/badge.svg?style=flat-square\n[snyk-url]: https://snyk.io/test/npm/easywebpack-html\n[download-image]: https://img.shields.io/npm/dm/easywebpack-html.svg?style=flat-square\n[download-url]: https://npmjs.org/package/easywebpack-html\n\nstatic html webpack build for easywebpack.\n\n- support static html template\n- support nunjucks html template\n\n## Version\n\n- easywebpack ^4.x.x \u003e webpack 4.x.x\n- easywebpack ^3.x.x \u003e webpack 3.x.x \n\n## Install\n\n```bash\n$ npm i easywebpack-html --save-dev\n```\n\n## Usage\n\n```js\n// build/index.js\nconst HtmlWebpack = require('easywebpack-html');\nconst config = {\n  entry: {\n    index: './src/index.js'\n  },\n  template: 'view/layout.html'\n};\n\nif (process.env.NODE_SERVER) {\n  // development mode: webpack building and start webpack hot server\n  HtmlWebpack.server(config);\n} else {\n  // webpack build file to disk\n  HtmlWebpack.build(config);\n}\n```\n\n## Run\n\n```js\n{\n \"scripts\": {\n   \"build\": \"cross-env NODE_ENV=development node build\",\n   \"start\" : \"cross-env NODE_SERVER=true NODE_ENV=development node build\"\n }\n}\n```\n\n```bash\n\nnpm start\n\n```\n\n## Example\n\n- [easywebpack-multiple-html-boilerplate](https://github.com/hubcarl/easywebpack-multiple-html-boilerplate) Multiple static html build boilerplate.\n\n- you can use [easywebpack-cli](https://github.com/hubcarl/easywebpack-cli) create multiple static html build boilerplate.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feasy-team%2Feasywebpack-html","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feasy-team%2Feasywebpack-html","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feasy-team%2Feasywebpack-html/lists"}