Skip to content

TypeScript API / contentia/sanitizer / SanitizeOptions

Interface: SanitizeOptions ​

Options for sanitization

Properties ​

ignoreExtensions? ​

ts
ignoreExtensions?: string[];

File extensions to ignore (pass through unchanged without sanitization). Use this when you have other security measures in place for certain file types.

Example: ['pdf', 'jpeg', 'jpg'] - these files will be returned unchanged

WARNING: Use with caution - this bypasses security checks for the specified file types.

Default ​

ts
[]

maxFileSize? ​

ts
maxFileSize?: number;

Maximum file size in bytes

Default ​

ts
104857600 (100MB)