🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

@arcjet/headers

Package Overview
Dependencies
Maintainers
3
Versions
47
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@arcjet/headers - npm Package Compare versions

Comparing version
1.0.0-beta.9
to
1.0.0-beta.10
+7
-7
package.json
{
"name": "@arcjet/headers",
"version": "1.0.0-beta.9",
"version": "1.0.0-beta.10",
"description": "Arcjet extension of the Headers class",

@@ -47,9 +47,9 @@ "keywords": [

"devDependencies": {
"@arcjet/eslint-config": "1.0.0-beta.9",
"@arcjet/rollup-config": "1.0.0-beta.9",
"@arcjet/tsconfig": "1.0.0-beta.9",
"@rollup/wasm-node": "4.44.2",
"@arcjet/eslint-config": "1.0.0-beta.10",
"@arcjet/rollup-config": "1.0.0-beta.10",
"@arcjet/tsconfig": "1.0.0-beta.10",
"@rollup/wasm-node": "4.46.2",
"@types/node": "18.18.0",
"eslint": "9.30.1",
"typescript": "5.8.3"
"eslint": "9.32.0",
"typescript": "5.9.2"
},

@@ -56,0 +56,0 @@ "publishConfig": {

+21
-11

@@ -24,9 +24,23 @@ <a href="https://arcjet.com" target="_arcjet-home">

## Installation
## What is this?
```shell
npm install -S @arcjet/headers
This is an internal utility to help us deal with [`Headers`][mdn-headers].
This exists to prevent the `cookie` header from being set and non-string values
from being set.
## When should I use this?
You should not use this but use `Headers` or plain objects instead.
This package matches our current needs which are likely different from yours.
## Install
This package is ESM only.
Install with npm in Node.js:
```sh
npm install @arcjet/headers
```
## Example
## Use

@@ -38,15 +52,11 @@ ```ts

console.log(headers.get("abc"));
console.log(headers.get("abc")); // => "123"
```
## Considerations
This package will filter the `cookie` header and all headers with keys or values
that are not strings, such as `{ "abc": undefined }`.
## License
Licensed under the [Apache License, Version 2.0][apache-license].
[Apache License, Version 2.0][apache-license] © [Arcjet Labs, Inc.][arcjet]
[arcjet]: https://arcjet.com
[apache-license]: http://www.apache.org/licenses/LICENSE-2.0
[mdn-headers]: https://developer.mozilla.org/en-US/docs/Web/API/Headers