mirror of
https://codeberg.org/SafeTwitch/safetwitch-backend.git
synced 2025-03-12 06:01:37 -05:00
9 lines
No EOL
305 B
TypeScript
9 lines
No EOL
305 B
TypeScript
import { NextFunction, Request, Response } from "express";
|
|
|
|
export const cors = () => {
|
|
return (req: Request, res: Response, next: NextFunction) => {
|
|
res.header("Access-Control-Allow-Origin", "*");
|
|
res.header("Access-Control-Allow-Headers", "X-Requested-With");
|
|
next();
|
|
}
|
|
} |