Socket
Socket
Sign inDemoInstall

fastify-static

Package Overview
Dependencies
19
Maintainers
6
Versions
55
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.0 to 0.4.0

4

index.js

@@ -67,3 +67,3 @@ 'use strict'

fastify.decorateReply('sendFile', function (filePath) {
pumpSendToReply(this._req, this, filePath)
pumpSendToReply(this.request.req, this, filePath)
})

@@ -102,2 +102,2 @@

module.exports = fp(fastifyStatic)
module.exports = fp(fastifyStatic, '>= 0.35.0')
{
"name": "fastify-static",
"version": "0.3.0",
"version": "0.4.0",
"description": "Plugin for serving static files as fast as possible.",

@@ -33,3 +33,3 @@ "main": "index.js",

"coveralls": "^3.0.0",
"fastify": "^0.30.2",
"fastify": "^0.35.0",
"pre-commit": "^1.2.2",

@@ -36,0 +36,0 @@ "request": "^2.81.0",

@@ -12,3 +12,3 @@ # fastify-static [![Build Status](https://travis-ci.org/fastify/fastify-static.svg?branch=master)](https://travis-ci.org/fastify/fastify-static) [![Greenkeeper badge](https://badges.greenkeeper.io/fastify/fastify-static.svg)](https://greenkeeper.io/) [![Known Vulnerabilities](https://snyk.io/test/github/fastify/fastify-static/badge.svg)](https://snyk.io/test/github/fastify/fastify-static)

```js
const fastify = require('fastify')
const fastify = require('fastify')()
const path = require('path')

@@ -18,3 +18,3 @@

root: path.join(__dirname, 'public'),
prefix: '/public/' // optional: default '/'
prefix: '/public/', // optional: default '/'
page404Path: path.join(__dirname, 'public', '404.html'), // optional

@@ -21,0 +21,0 @@ page403Path: path.join(__dirname, 'public', '403.html'), // optional

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc