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

expand-range

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

expand-range - npm Package Compare versions

Comparing version 1.5.0 to 1.6.0

21

index.js

@@ -12,3 +12,3 @@ /*!

module.exports = function expandRange(str, fn) {
module.exports = function expandRange(str, options, fn) {
if (typeof str !== 'string') {

@@ -18,3 +18,14 @@ throw new TypeError('expand-range expects a string.');

if (typeof options === 'function') {
fn = options;
options = {};
}
if (typeof options === 'boolean') {
options = {};
options.makeRe = true;
}
// create arguments to pass to fill-range
var opts = options || {};
var args = str.split('..');

@@ -28,11 +39,7 @@ var len = args.length;

if (typeof fn === 'boolean' && fn === true) {
fn = '~';
if (len === 3) {
args[len - 1] += fn;
fn = null;
}
opts.makeRe = true;
}
args.push(opts);
return fill.apply(fill, args.concat(fn));
};
{
"name": "expand-range",
"description": "Fast, bash-like range expansion. Expand a range of numbers or letters, uppercase or lowercase. See the benchmarks. Used by micromatch.",
"version": "1.5.0",
"version": "1.6.0",
"homepage": "https://github.com/jonschlinkert/expand-range",

@@ -32,3 +32,3 @@ "author": {

"dependencies": {
"fill-range": "^1.7.1"
"fill-range": "^1.9.0"
},

@@ -35,0 +35,0 @@ "devDependencies": {

@@ -103,3 +103,3 @@ # expand-range [![NPM version](https://badge.fury.io/js/expand-range.svg)](http://badge.fury.io/js/expand-range)

_This file was generated by [verb](https://github.com/assemble/verb) on January 24, 2015._
_This file was generated by [verb](https://github.com/assemble/verb) on January 25, 2015._

@@ -106,0 +106,0 @@ [fill-range]: https://github.com/jonschlinkert/fill-range

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