abaga129 / sveltekit-adapter-iis

15 stars 5 forks source link

Added config for httpErrors #23

Closed Palkess closed 1 month ago

Palkess commented 1 month ago

In our application we don't want to rely on the IIS server serving the default [STATUS].htm file whenever the user encounters a 4xx error and a global setting for all our IIS websites in the IIS server isn't desirable, as some websites rely on the default handling of errors in IIS. We'd rather pass through the error handling to the SvelteKit application.

I've added an optional config for setting the httpErrors.existingResponse attribute to Auto, Replace or PassThrough. The httpErrors-config could be extended to include more attributes in the future, as specified in the \<httpErrors>-docs, but I'm not familiar enough with the other attributes to know if some other config is required as well.

abaga129 commented 1 month ago

I'm not familiar with this IIS setting, but everything looks good to me so I'll go ahead and merge. Thanks!

abaga129 commented 1 month ago

This has been published as v1.3.0