mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 03:29:51 +02:00
8 lines
184 B
TypeScript
8 lines
184 B
TypeScript
import { context } from './context';
|
|
|
|
export function withCORSProxy(url: string) {
|
|
return context === 'website'
|
|
? `https://corsproxy.io/?${encodeURIComponent(url)}`
|
|
: url;
|
|
}
|