@sveltejs/adapter-node
Advanced tools
Comparing version 1.0.0-next.18 to 1.0.0-next.19
# @sveltejs/adapter-node | ||
## 1.0.0-next.19 | ||
### Patch Changes | ||
- 0e09581: Make host configurable via process.env.HOST | ||
## 1.0.0-next.18 | ||
@@ -4,0 +10,0 @@ |
{ | ||
"name": "@sveltejs/adapter-node", | ||
"version": "1.0.0-next.18", | ||
"version": "1.0.0-next.19", | ||
"type": "module", | ||
@@ -16,3 +16,3 @@ "exports": { | ||
"@rollup/plugin-json": "^4.1.0", | ||
"@sveltejs/kit": "1.0.0-next.98", | ||
"@sveltejs/kit": "1.0.0-next.102", | ||
"c8": "^7.7.2", | ||
@@ -22,3 +22,3 @@ "compression": "^1.7.4", | ||
"polka": "^1.0.0-next.14", | ||
"rollup": "^2.46.0", | ||
"rollup": "^2.47.0", | ||
"sirv": "^1.0.11", | ||
@@ -25,0 +25,0 @@ "typescript": "^4.2.4", |
@@ -1,5 +0,39 @@ | ||
# adapter-node | ||
# @sveltejs/adapter-node | ||
Adapter for Svelte apps that builds a Node server — the equivalent of `sapper build`. | ||
[Adapter](https://kit.svelte.dev/docs#adapters) for SvelteKit apps that generates a standalone Node server. | ||
This is very experimental; the adapter API isn't at all fleshed out, and things will definitely change. | ||
## Usage | ||
Install with `npm i -D @sveltejs/adapter-node@next`, then add the adapter to your `svelte.config.js`: | ||
```js | ||
// svelte.config.js | ||
import adapter from '@sveltejs/adapter-node'; | ||
export default { | ||
kit: { | ||
adapter: adapter({ | ||
// default options are shown | ||
out: 'build' | ||
}) | ||
} | ||
}; | ||
``` | ||
## Options | ||
### out | ||
The directory to build the server to. It defaults to `build` — i.e. `node build` would start the server locally after it has been created. | ||
## Environment variables | ||
By default, the server will accept connections on `0.0.0.0` using port 3000. These can be customised with the `PORT` and `HOST` environment variables: | ||
``` | ||
HOST=127.0.0.1 PORT=4000 node build | ||
``` | ||
## License | ||
[MIT](LICENSE) |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
604488
15030
40