@settlemint/sdk-next
Version:
Next.js integration module for SettleMint SDK, providing React components and middleware for web applications
35 lines (33 loc) • 917 B
JavaScript
//#region src/config/with-settlemint.ts
/**
* Modifies the passed in Next.js configuration with SettleMint-specific settings.
*
* @param nextConfig - The original Next.js configuration
* @param options - Options for customizing the SettleMint configuration
* @returns The modified Next.js configuration
* @throws If the SettleMint configuration cannot be read or processed
*/
async function withSettleMint(nextConfig, { disabled = false } = {}) {
if (disabled) return nextConfig;
const baseConfig = { ...nextConfig };
return {
...baseConfig,
headers: async () => [{
source: "/(.*)",
headers: [{
key: "X-Frame-Options",
value: "DENY"
}]
}],
poweredByHeader: false,
reactStrictMode: true
};
}
//#endregion
Object.defineProperty(exports, 'withSettleMint', {
enumerable: true,
get: function () {
return withSettleMint;
}
});
//# sourceMappingURL=with-settlemint-D3TfnuaY.cjs.map