awesome-uses/server.ts

22 lines
569 B
TypeScript
Raw Permalink Normal View History

2023-02-21 20:37:44 +00:00
// Import path interpreted by the Remix compiler
2023-04-13 18:06:16 +00:00
import * as build from '@remix-run/dev/server-build';
import { createRequestHandler } from '@netlify/remix-edge-adapter';
2023-02-20 20:41:29 +00:00
2023-02-21 20:37:44 +00:00
export default createRequestHandler({
2023-02-20 20:41:29 +00:00
build,
2023-02-21 20:37:44 +00:00
// process.env.NODE_ENV is provided by Remix at compile time
2023-02-20 20:41:29 +00:00
mode: process.env.NODE_ENV,
});
2023-02-22 20:24:47 +00:00
export const config = {
2023-04-13 18:06:16 +00:00
cache: 'manual',
path: '/*',
2023-02-23 14:10:33 +00:00
// Pass all assets to the netlify asset server
2023-04-13 18:06:16 +00:00
excluded_patterns: [
'^\\/_assets\\/[^\\/]*$',
'^\\/shared\\/[^\\/]*$',
2023-04-14 13:37:17 +00:00
'^\\/build\\/[^\\/]*$',
2023-04-13 18:06:16 +00:00
// '^\\/**\\/[^\\/]*$',
],
2023-02-22 20:24:47 +00:00
};