Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

nuxt-multi-cache

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nuxt-multi-cache - npm Package Compare versions

Comparing version 1.0.5 to 1.1.0

16

lib/cjs/module.js

@@ -31,3 +31,3 @@ "use strict";

const nuxt = this.nuxt;
const provided = this.options.routeCache || {};
const provided = this.options.multiCache || {};
const enabled = !!provided.enabled;

@@ -75,4 +75,6 @@ const enabledForRequest = provided.enabledForRequest || defaultEnabledForRequest;

}
if (!provided.server || typeof provided.server.auth !== 'object' && typeof provided.server.auth !== 'function') {
logger('No serverAuth function or basic auth config provided, caching is disabled.', 'warn');
if (!provided.server ||
(typeof provided.server.auth !== 'object' &&
typeof provided.server.auth !== 'function')) {
logger('No server.auth function or basic auth config provided, caching is disabled.', 'warn');
return;

@@ -84,3 +86,5 @@ }

let groupsCache = null;
if (configComponentCache && configComponentCache.enabled && this.options.render.bundleRenderer) {
if (configComponentCache &&
configComponentCache.enabled &&
this.options.render.bundleRenderer) {
componentCache = new Component_1.default(configComponentCache);

@@ -136,3 +140,5 @@ this.options.render.bundleRenderer.cache = componentCache;

return renderRoute(route, context).then((result) => {
if (pageCache && context.$cacheHelper && context.$cacheHelper.cacheable) {
if (pageCache &&
context.$cacheHelper &&
context.$cacheHelper.cacheable) {
const tags = context.$cacheHelper.tags || [];

@@ -139,0 +145,0 @@ pageCache

@@ -26,3 +26,3 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {

const nuxt = this.nuxt;
const provided = this.options.routeCache || {};
const provided = this.options.multiCache || {};
const enabled = !!provided.enabled;

@@ -70,4 +70,6 @@ const enabledForRequest = provided.enabledForRequest || defaultEnabledForRequest;

}
if (!provided.server || typeof provided.server.auth !== 'object' && typeof provided.server.auth !== 'function') {
logger('No serverAuth function or basic auth config provided, caching is disabled.', 'warn');
if (!provided.server ||
(typeof provided.server.auth !== 'object' &&
typeof provided.server.auth !== 'function')) {
logger('No server.auth function or basic auth config provided, caching is disabled.', 'warn');
return;

@@ -79,3 +81,5 @@ }

let groupsCache = null;
if (configComponentCache && configComponentCache.enabled && this.options.render.bundleRenderer) {
if (configComponentCache &&
configComponentCache.enabled &&
this.options.render.bundleRenderer) {
componentCache = new ComponentCache(configComponentCache);

@@ -131,3 +135,5 @@ this.options.render.bundleRenderer.cache = componentCache;

return renderRoute(route, context).then((result) => {
if (pageCache && context.$cacheHelper && context.$cacheHelper.cacheable) {
if (pageCache &&
context.$cacheHelper &&
context.$cacheHelper.cacheable) {
const tags = context.$cacheHelper.tags || [];

@@ -134,0 +140,0 @@ pageCache

{
"name": "nuxt-multi-cache",
"version": "1.0.5",
"version": "1.1.0",
"description": "SSR route, component and data cache for Nuxt.js",

@@ -5,0 +5,0 @@ "keywords": [

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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