@resonatehq/supabase 0.1.3 → 0.1.4
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/dist/index.d.ts +1 -0
- package/dist/index.js +11 -0
- package/package.json +2 -1
- package/src/index.ts +12 -0
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -113,6 +113,17 @@ class Resonate {
|
|
|
113
113
|
}), { status: 500 });
|
|
114
114
|
}
|
|
115
115
|
}
|
|
116
|
+
httpHandler() {
|
|
117
|
+
return Deno.serve(async (req) => {
|
|
118
|
+
const resp = await this.handler(req);
|
|
119
|
+
return new Response(JSON.stringify(resp), {
|
|
120
|
+
headers: {
|
|
121
|
+
"Content-Type": "application/json",
|
|
122
|
+
Connection: "keep-alive",
|
|
123
|
+
},
|
|
124
|
+
});
|
|
125
|
+
});
|
|
126
|
+
}
|
|
116
127
|
}
|
|
117
128
|
exports.Resonate = Resonate;
|
|
118
129
|
function buildForwardedURL(req) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@resonatehq/supabase",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.4",
|
|
4
4
|
"description": "Resonate FaaS handler for Supabase Edge Functions (TypeScript)",
|
|
5
5
|
"repository": {
|
|
6
6
|
"url": "https://github.com/resonatehq/resonate-faas-supabase-ts"
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
"devDependencies": {
|
|
24
24
|
"@biomejs/biome": "2.3.6",
|
|
25
25
|
"@types/bun": "latest",
|
|
26
|
+
"@types/deno": "^2.5.0",
|
|
26
27
|
"open": "^10.2.0"
|
|
27
28
|
},
|
|
28
29
|
"peerDependencies": {
|
package/src/index.ts
CHANGED
|
@@ -199,6 +199,18 @@ export class Resonate {
|
|
|
199
199
|
);
|
|
200
200
|
}
|
|
201
201
|
}
|
|
202
|
+
|
|
203
|
+
public httpHandler(): Deno.HttpServer {
|
|
204
|
+
return Deno.serve(async (req: Request) => {
|
|
205
|
+
const resp = await this.handler(req);
|
|
206
|
+
return new Response(JSON.stringify(resp), {
|
|
207
|
+
headers: {
|
|
208
|
+
"Content-Type": "application/json",
|
|
209
|
+
Connection: "keep-alive",
|
|
210
|
+
},
|
|
211
|
+
});
|
|
212
|
+
});
|
|
213
|
+
}
|
|
202
214
|
}
|
|
203
215
|
|
|
204
216
|
function buildForwardedURL(req: Request) {
|