@arcjet/astro 1.1.0-rc → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/internal.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import type { ArcjetDecision, ArcjetOptions as CoreOptions, Primitive, Product, ExtraProps, CharacteristicProps } from "arcjet";
1
+ import type { ArcjetDecision, ArcjetOptions as CoreOptions, ArcjetRule, Primitive, Product, ExtraProps, CharacteristicProps } from "arcjet";
2
2
  export * from "arcjet";
3
3
  type Simplify<T> = {
4
4
  [KeyType in keyof T]: T[KeyType];
@@ -101,7 +101,7 @@ export interface ArcjetAstro<Props extends PlainObject> {
101
101
  * @returns
102
102
  * Arcjet instance augmented with the given rule.
103
103
  */
104
- withRule<ChildProperties extends PlainObject>(rule: Primitive<ChildProperties> | Product<ChildProperties>): ArcjetAstro<Props & ChildProperties>;
104
+ withRule<Rule extends ArcjetRule>(rule: Array<Rule>): ArcjetAstro<Props & (Rule extends ArcjetRule<infer P> ? P : {})>;
105
105
  }
106
106
  /**
107
107
  * Create a new Astro integration of Arcjet.
package/internal.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import core__default from 'arcjet';
2
2
  export * from 'arcjet';
3
3
  import { readBodyWeb } from '@arcjet/body';
4
- import findIp, { parseProxy } from '@arcjet/ip';
4
+ import { parseProxy, findIp } from '@arcjet/ip';
5
5
  import { ArcjetHeaders } from '@arcjet/headers';
6
6
  import { logLevel, isDevelopment, baseUrl, platform } from '@arcjet/env';
7
7
  import { Logger } from '@arcjet/logger';
@@ -40,7 +40,7 @@ function createRemoteClient(options) {
40
40
  // Transport is the HTTP client that the client uses to make requests.
41
41
  const transport = createTransport(url);
42
42
  const sdkStack = "ASTRO";
43
- const sdkVersion = "1.1.0-rc";
43
+ const sdkVersion = "1.1.0";
44
44
  return createClient({
45
45
  transport,
46
46
  baseUrl: url,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcjet/astro",
3
- "version": "1.1.0-rc",
3
+ "version": "1.1.0",
4
4
  "description": "Arcjet helps developers protect their Astro sites in just a few lines of code. Bot detection. Rate limiting. Email validation. Attack protection. Data redaction. A developer-first approach to security.",
5
5
  "keywords": [
6
6
  "analyze",
@@ -51,23 +51,23 @@
51
51
  "test": "npm run build && npm run lint && npm run test-coverage"
52
52
  },
53
53
  "dependencies": {
54
- "@arcjet/body": "1.1.0-rc",
55
- "@arcjet/env": "1.1.0-rc",
56
- "@arcjet/headers": "1.1.0-rc",
57
- "@arcjet/ip": "1.1.0-rc",
58
- "@arcjet/logger": "1.1.0-rc",
59
- "@arcjet/protocol": "1.1.0-rc",
60
- "@arcjet/transport": "1.1.0-rc",
61
- "arcjet": "1.1.0-rc"
54
+ "@arcjet/body": "1.1.0",
55
+ "@arcjet/env": "1.1.0",
56
+ "@arcjet/headers": "1.1.0",
57
+ "@arcjet/ip": "1.1.0",
58
+ "@arcjet/logger": "1.1.0",
59
+ "@arcjet/protocol": "1.1.0",
60
+ "@arcjet/transport": "1.1.0",
61
+ "arcjet": "1.1.0"
62
62
  },
63
63
  "peerDependencies": {
64
64
  "astro": "^5.9.3"
65
65
  },
66
66
  "devDependencies": {
67
- "@arcjet/eslint-config": "1.1.0-rc",
68
- "@arcjet/rollup-config": "1.1.0-rc",
67
+ "@arcjet/eslint-config": "1.1.0",
68
+ "@arcjet/rollup-config": "1.1.0",
69
69
  "@rollup/wasm-node": "4.57.0",
70
- "astro": "5.16.15",
70
+ "astro": "5.16.16",
71
71
  "eslint": "9.39.2",
72
72
  "typescript": "5.9.3"
73
73
  },