You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
994 B

'use strict';
const responseHandlers = require('./src/response-handlers');
module.exports = [
'strapi::logger',
'strapi::errors',
{
name: 'strapi::security',
config: {
contentSecurityPolicy: {
useDefaults: true,
directives: {
'frame-src': ["'self'"], // URLs that will be loaded in an iframe (e.g. Content Preview)
// Needed to load the `@vercel/stega` lib on the dummy-preview page
'script-src': ["'self'", "'unsafe-inline'", 'https://cdn.jsdelivr.net'],
},
},
},
},
'strapi::cors',
'strapi::poweredBy',
'strapi::query',
'strapi::body',
'strapi::session',
// 'strapi::compression',
// 'strapi::ip',
{
name: 'strapi::responses',
config: {
handlers: responseHandlers,
},
},
'strapi::favicon',
'strapi::public',
{
name: 'global::test-middleware',
config: {
foo: 'bar',
},
},
{
resolve: './src/custom/middleware.js',
config: {},
},
];