🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis →
Socket
Book a DemoInstallSign in
Socket

@joinbox/loopback-component-custom-headers

Package Overview
Dependencies
Maintainers
2
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@joinbox/loopback-component-custom-headers

Adds custom headers to loopback responses according to the model configuration

latest
Source
npmnpm
Version
0.1.2
Version published
Maintainers
2
Created
Source

Loopback Component Custom Headers

Sets cache headers according to the model configuration

Add the following configuration to your model configuration if you want to enable custom headers.

MyModel {
    "options": {
        "setCustomHeaders": true,
        "customHeaders": {
            "Cache-Control": "public, max-age=86400",
            "Vary": "User-Agent"
        }
    }
}

Pameters:

  • setCustomHeaders: Boolean enables the feature for the given model.
  • customHeaders: Object adds all configured headers to the response where the key is the name of the header and the value the header value.

Keywords

loopback

FAQs

Package last updated on 21 Feb 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts