Skip to content

fix glob expandDirectories extension option gen glob#263

Merged
sindresorhus merged 1 commit intosindresorhus:mainfrom
rick-ame:glob-ext
Feb 11, 2024
Merged

fix glob expandDirectories extension option gen glob#263
sindresorhus merged 1 commit intosindresorhus:mainfrom
rick-ame:glob-ext

Conversation

@rick-ame
Copy link

When only set extensions option for expandDirectories like

const res = await globby(["tests"], {
  expandDirectories: {
     extensions: ["js"],
  },
});
console.log(res);

it gets an empty array even with js files existing because getDirectoryGlobgenerates tests/**/.js pattern which is invalid.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants