Socket
Socket
Sign inDemoInstall

@tinyhttp/app

Package Overview
Dependencies
Maintainers
1
Versions
305
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tinyhttp/app - npm Package Compare versions

Comparing version 2.0.21 to 2.0.22

1

dist/app.d.ts

@@ -16,2 +16,3 @@ /// <reference types="node" />

enableReqRoute: boolean;
views: string;
}>;

@@ -18,0 +19,0 @@ /**

4

dist/index.js

@@ -172,3 +172,3 @@ import { STATUS_CODES, createServer } from 'http';

this.noMatchHandler = (options === null || options === void 0 ? void 0 : options.noMatchHandler) || this.onError.bind(null, { code: 404 });
this.settings = options.settings || { xPoweredBy: true };
this.settings = options.settings || { xPoweredBy: true, views: process.cwd() };
this.applyExtensions = options === null || options === void 0 ? void 0 : options.applyExtensions;

@@ -210,3 +210,3 @@ this.attach = (req, res) => setImmediate(this.handler.bind(this, req, res, undefined), req, res);

render(file, data = {}, cb, options = {}) {
options.viewsFolder = options.viewsFolder || `${process.cwd()}/views`;
options.viewsFolder = options.viewsFolder || this.settings.views || `${process.cwd()}/views`;
options.ext = options.ext || file.slice(file.lastIndexOf('.') + 1) || 'ejs';

@@ -213,0 +213,0 @@ options._locals = options._locals || {};

/// <reference types="node" />
/// <reference types="node" />
/// <reference types="node" />
/// <reference types="node" />
import { IncomingMessage } from 'http';

@@ -3,0 +6,0 @@ import { ParsedUrlQuery } from 'querystring';

{
"name": "@tinyhttp/app",
"version": "2.0.21",
"version": "2.0.22",
"description": "0-legacy, tiny & fast web framework as a replacement of Express",

@@ -38,3 +38,3 @@ "type": "module",

"@tinyhttp/req": "2.0.13",
"@tinyhttp/res": "2.0.16",
"@tinyhttp/res": "2.0.17",
"@tinyhttp/router": "2.0.5",

@@ -41,0 +41,0 @@ "header-range-parser": "1.1.3",

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