Skip to content

Commit 8c34cf9

Browse files
update cors proxy server url (#31)
1 parent b535b9b commit 8c34cf9

3 files changed

Lines changed: 5 additions & 3 deletions

File tree

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@ import { makeWebHttpClient } from 'git-essentials/clients/request/WebHttpClient'
3333
// as a result the browser will refuse to serve the request.
3434
// To overcome this limitation CORS proxy server could be used.
3535
const corsProxyUrlTransformer = (originalUrl: string) => {
36-
return `https://www.noteshub.app/api/cors-proxy.ts?url=${encodeURIComponent(originalUrl)}`
36+
// Please use this CORS proxy server only for testing and not production use.
37+
// You can fork CORS proxy server from here https://github.com/alex-titarenko/gitcorsproxy
38+
return `https://gitcorsproxy.vercel.app/api/cors?url=${encodeURIComponent(originalUrl)}`
3739
}
3840

3941
const fs = new InMemoryFsClient()

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "git-essentials",
3-
"version": "0.6.6",
3+
"version": "0.7.0",
44
"description": "A collection of essential Git commands for your browser and Node.js",
55
"main": "dist/esm/index.js",
66
"types": "index.d.ts",

tests/helpers/integrationContext.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { join } from 'src/utils/join'
77
const isBrowser = () => typeof window !== `undefined`
88

99
const corsProxyUrlTransformer = (originalUrl: string) => {
10-
return `https://www.noteshub.app/api/cors-proxy.ts?url=${encodeURIComponent(originalUrl)}`
10+
return `https://gitcorsproxy.vercel.app/api/cors?url=${encodeURIComponent(originalUrl)}`
1111
}
1212

1313
type IntegrationContext = {

0 commit comments

Comments
 (0)