Socket
Socket
Sign inDemoInstall

styled-components

Package Overview
Dependencies
Maintainers
2
Versions
358
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

styled-components - npm Package Compare versions

Comparing version 0.1.7 to 0.1.8

2

lib/utils/flatten.js

@@ -27,3 +27,3 @@ 'use strict';

/* Remove falsey values */
if (!chunk) return array;
if (chunk === undefined || chunk === null || chunk === false || chunk === '') return array;
/* Flatten arrays */

@@ -30,0 +30,0 @@ if (Array.isArray(chunk)) return array.concat.apply(array, _toConsumableArray(flatten(chunk, executionContext)));

@@ -20,2 +20,5 @@ 'use strict';

});
it('doesnt drop any numbers', function () {
(0, _expect2.default)((0, _flatten2.default)(['foo', 0, 'bar', NaN, 'baz', -1])).toEqual(['foo', '0', 'bar', 'NaN', 'baz', '-1']);
});
it('toStrings everything', function () {

@@ -22,0 +25,0 @@ (0, _expect2.default)((0, _flatten2.default)([1, true])).toEqual(['1', 'true']);

{
"name": "styled-components",
"version": "0.1.7",
"version": "0.1.8",
"description": "",

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

@@ -12,3 +12,3 @@ // @flow

/* Remove falsey values */
if (!chunk) return array
if (chunk === undefined || chunk === null || chunk === false || chunk === '') return array
/* Flatten arrays */

@@ -15,0 +15,0 @@ if (Array.isArray(chunk)) return array.concat(...flatten(chunk, executionContext))

@@ -11,2 +11,5 @@ import expect from 'expect'

})
it('doesnt drop any numbers', () => {
expect(flatten(['foo', 0, 'bar', NaN, 'baz', -1])).toEqual(['foo', '0', 'bar', 'NaN', 'baz', '-1'])
})
it('toStrings everything', () => {

@@ -13,0 +16,0 @@ expect(flatten([1, true])).toEqual(['1', 'true'])

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