New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mimeware

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mimeware - npm Package Compare versions

Comparing version 0.1.0 to 0.1.1

2

package.json
{
"name": "mimeware",
"description": "Cross-framework HTTP middleware to infer the proper MIME content type response header",
"version": "0.1.0",
"version": "0.1.1",
"license": "MIT",

@@ -6,0 +6,0 @@ "repository": "h2non/mimeware",

@@ -1,2 +0,2 @@

# mimeware [![Build Status](https://api.travis-ci.org/h2non/mimeware.svg?branch=master)][travis] [![Dependency Status](https://gemnasium.com/h2non/mimeware.svg)][gemnasium] [![NPM version](https://badge.fury.io/js/mimewire.svg)][npm]
# mimeware [![Build Status](https://api.travis-ci.org/h2non/mimeware.svg?branch=master)][travis] [![Dependency Status](https://gemnasium.com/h2non/mimeware.svg)][gemnasium] [![NPM version](https://badge.fury.io/js/mimeware.svg)][npm]

@@ -15,3 +15,3 @@ Node.js HTTP server middleware to infer and define the proper MIME content type as response header

```bash
npm install mimewire --save
npm install mimeware --save
```

@@ -23,10 +23,21 @@

var express = require('express')
var mimewire = require('mimewire')
var mimeware = require('mimeware')
var app = express()
app.use(mimewire({ defaultType: 'text/html' }))
app.use(mimeware({ defaultType: 'text/html' }))
app.get('/hello', function (req, res, next) {
// respond with default type: text/html
res.send('Hello World!')
})
app.get('/hello.json', function (req, res, next) {
// respond with type: application/json
res.json({ say: 'Hello World!' })
})
app.get('/hello.xml', function (req, res, next) {
// respond with type: text/xml
res.send('<say>Hello World!</say>')
})
```

@@ -33,0 +44,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc