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

cloudimage-responsive-utils

Package Overview
Dependencies
Maintainers
2
Versions
65
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cloudimage-responsive-utils - npm Package Compare versions

Comparing version 2.1.0-beta.1 to 2.2.0

5

CHANGELOG.MD

@@ -29,2 +29,7 @@ # Changelog

# 2.2.0 - 2021-06-16
### Added
- set a custom domain property. This is useful for where a business wants to use a custom cname instead of the default
cloudimage.io URL.
# 2.1.0 - 2020-12-17

@@ -31,0 +36,0 @@ ### Added

6

dist/utils/generate-url.js

@@ -51,4 +51,6 @@ "use strict";

domain = config.domain,
doNotReplaceURL = config.doNotReplaceURL;
var url = [doNotReplaceURL ? '' : "https://".concat(token, ".").concat(domain, "/v7/"), src, src.indexOf('?') !== -1 ? '&' : '?'].join('');
doNotReplaceURL = config.doNotReplaceURL,
customDomain = config.customDomain;
var finalDomain = customDomain ? domain : token + '.' + domain;
var url = [doNotReplaceURL ? '' : "https://".concat(finalDomain, "/v7/"), src, src.indexOf('?') !== -1 ? '&' : '?'].join('');
return [processURL ? processURL({

@@ -55,0 +57,0 @@ url: url,

{
"name": "cloudimage-responsive-utils",
"version": "2.1.0-beta.1",
"version": "2.2.0",
"description": "cloudimage responsive utils",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

@@ -8,5 +8,8 @@ import { DEVICE_PIXEL_RATIO_LIST } from '../constants';

const { width, height } = size || {};
const { token, domain, doNotReplaceURL } = config;
const { token, domain, doNotReplaceURL, customDomain } = config;
const finalDomain = customDomain ? domain : token + '.' + domain;
const url =[
doNotReplaceURL ? '' : `https://${token}.${domain}/v7/`,
doNotReplaceURL ? '' : `https://${finalDomain}/v7/`,
src,

@@ -13,0 +16,0 @@ src.includes('?') ? '&' : '?'

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