findConfig is a noop instead of throwing an error
Author: tomzvCreated Apr 9, 2024Updated Apr 9, 2024
Hello, when creating a browserslist instance, the options object you can provide can include a path property that provides, according to the README file -> file or a directory path to look for config file.
When providing the path property in a browser environment, it just silently results in a noop when calling findConfig(), unlike when for example providing the config argument, (which throws an error when calling loadConfig() from the browser).
Wouldn't it be preferable to throw an error for the path property as well, to alert the user of the library of the fact that the path argument behaves differently in the browser? Is there a specific reason for the noop as opposed to throwing an error message?
Source: browserslist/browserslist