{"id":13681422,"url":"https://github.com/ericclemmons/start-server-webpack-plugin","last_synced_at":"2025-04-05T04:10:51.428Z","repository":{"id":57119993,"uuid":"55939071","full_name":"ericclemmons/start-server-webpack-plugin","owner":"ericclemmons","description":"Automatically start your server once Webpack's build completes.","archived":false,"fork":false,"pushed_at":"2023-04-17T04:01:29.000Z","size":312,"stargazers_count":159,"open_issues_count":17,"forks_count":26,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-28T19:51:34.516Z","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":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ericclemmons.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.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":"2016-04-11T03:33:40.000Z","updated_at":"2025-03-23T22:57:51.000Z","dependencies_parsed_at":"2024-06-16T17:44:56.121Z","dependency_job_id":"bbca7d17-6dc2-40a1-855c-a06cff65a0f1","html_url":"https://github.com/ericclemmons/start-server-webpack-plugin","commit_stats":{"total_commits":39,"total_committers":7,"mean_commits":5.571428571428571,"dds":0.3846153846153846,"last_synced_commit":"2d44cc5403c5a99ced12b924d4c23a51c5b062ac"},"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericclemmons%2Fstart-server-webpack-plugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericclemmons%2Fstart-server-webpack-plugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericclemmons%2Fstart-server-webpack-plugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericclemmons%2Fstart-server-webpack-plugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ericclemmons","download_url":"https://codeload.github.com/ericclemmons/start-server-webpack-plugin/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247284949,"owners_count":20913704,"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":[],"created_at":"2024-08-02T13:01:30.575Z","updated_at":"2025-04-05T04:10:51.398Z","avatar_url":"https://github.com/ericclemmons.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# start-server-webpack-plugin\n\n\u003e Automatically start your server once Webpack's build completes.\n\n[![travis build](https://img.shields.io/travis/ericclemmons/start-server-webpack-plugin.svg)](https://travis-ci.org/ericclemmons/start-server-webpack-plugin)\n[![version](https://img.shields.io/npm/v/start-server-webpack-plugin.svg)](http://npm.im/start-server-webpack-plugin)\n[![downloads](https://img.shields.io/npm/dm/start-server-webpack-plugin.svg)](http://npm-stat.com/charts.html?package=start-server-webpack-plugin)\n[![MIT License](https://img.shields.io/npm/l/start-server-webpack-plugin.svg)](http://opensource.org/licenses/MIT)\n\n### Installation\n\n```shell\n$ npm install --save-dev start-server-webpack-plugin\n```\n\n### Usage\n\nIn `webpack.config.server.babel.js`:\n\n```js\nimport StartServerPlugin from \"start-server-webpack-plugin\";\n\nexport default {\n  // This script will be ran after building\n  entry: {\n    server: ...\n  },\n  ...\n  plugins: [\n    ...\n    // Only use this in DEVELOPMENT\n    new StartServerPlugin({\n      name: 'server.js',\n      nodeArgs: ['--inspect'], // allow debugging\n      args: ['scriptArgument1', 'scriptArgument2'], // pass args to script\n      signal: false | true | 'SIGUSR2', // signal to send for HMR (defaults to `false`, uses 'SIGUSR2' if `true`)\n      keyboard: true | false, // Allow typing 'rs' to restart the server. default: only if NODE_ENV is 'development'\n    }),\n    ...\n  ],\n  ...\n}\n```\n\nThe `name` argument in `new StartServerPlugin(name)` refers to the built asset, which is named by the output options of webpack (in the example the entry `server` becomes `server.js`. This way, the plugin knows which entry to start in case there are several.\n\nIf you don't pass a name, the plugin will tell you the available names.\n\nYou can use `nodeArgs` and `args` to pass arguments to node and your script, respectively. For example, you can use this to use the node debugger.\n\nTo use Hot Module Reloading with your server code, set Webpack to \"hot\" mode and include the `webpack/hot/poll` or `webpack/hot/signal` modules. Make sure they are part of your server bundle, e.g. if you are using `node-externals` put them in your whitelist. The latter module requires the `signal` option.\n\n### License\n\n\u003e MIT License 2016 © Eric Clemmons\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fericclemmons%2Fstart-server-webpack-plugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fericclemmons%2Fstart-server-webpack-plugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fericclemmons%2Fstart-server-webpack-plugin/lists"}