Skip to content

Commit

Permalink
add cors origin configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
marcosparajua committed May 19, 2024
1 parent 6bc15b9 commit e0a678d
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,12 @@ export const startApp = (app: Express, prisma: PrismaClient) => {
debug('Starting app');
app.use(express.json());
app.use(morgan('dev'));
app.use(cors());
app.use(
cors({
origin: 'https://hyph4e.netlify.app/',
credentials: true,
})
);
app.use(express.static('public'));

const authInterceptor = new AuthInterceptor();
Expand Down

0 comments on commit e0a678d

Please sign in to comment.