-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding contentType cli option to address #276 #288
base: master
Are you sure you want to change the base?
Conversation
Hey @howardroark, couple of linting issues on this failed the CI build. |
d9bd690
to
d127273
Compare
Thanks @Jameskmonger ! Fixed ;) |
@Jameskmonger Hi, will this be merged ? It is very useful in my case where I have static website and prefer the urls to be of a form Just a small note, its not very correct that |
@@ -26,6 +26,7 @@ if (argv.h || argv.help) { | |||
' -s --silent Suppress log messages from output', | |||
' --cors[=headers] Enable CORS via the "Access-Control-Allow-Origin" header', | |||
' Optionally provide CORS headers list separated by commas', | |||
' --contentType Use a custom Content-Type response header for all requests', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should match the style of other switches by using --content-type
@@ -26,6 +26,7 @@ if (argv.h || argv.help) { | |||
' -s --silent Suppress log messages from output', | |||
' --cors[=headers] Enable CORS via the "Access-Control-Allow-Origin" header', | |||
' Optionally provide CORS headers list separated by commas', | |||
' --contentType Use a custom Content-Type response header for all requests', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The contentType
option actually is used for fallback, so maybe we could clarify by saying something like "Default Content-Type if it cannot be determined"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
possibly even more clear, though a long option, --default-content-type
?
I know this PR is a few years old, @howardroark I can take this over if you'd like me to |
Oh boy. |
fixes #296, fixes #276