Skip to content

Conversation

ChaosAttractor
Copy link

No description provided.

@bjohansebas
Copy link
Member

Can you give us more information about this MIME?

@ChaosAttractor
Copy link
Author

I apologize for the wait.

.log files are associated with text/x-log if the file implements Express.Multer.File (express, nest.js file handler)

image

and text/plain if

file --mime-type -b test.log
# output will be text/plain and inode/x-empty if file is empty

or

import path from 'path';
import mime from 'mime-types';

const ext = path.extname('./test.log');
const mimetype = mime.lookup(ext);

console.log(ext, mimetype);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants