\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6772}{}\doxysection{5.\+2.\+1}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6772}

\begin{DoxyItemize}
\item Chore\+: Upgrade {\ttfamily js-\/yaml} to avoid npm audit warning.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6773}{}\doxysection{5.\+2.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6773}

\begin{DoxyItemize}
\item Added\+: {\ttfamily package\+Prop} values can be arrays of strings, to allow for property names that include periods. (This was possible before, but not documented or deliberately supported.)
\item Chore\+: Replaced the {\ttfamily lodash.\+get} dependency with a locally defined function.
\item Chore\+: Upgrade {\ttfamily js-\/yaml} to avoid npm audit warning.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6774}{}\doxysection{5.\+1.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6774}

\begin{DoxyItemize}
\item Added\+: {\ttfamily package\+Prop} values can include periods to describe paths to nested objects within {\ttfamily package.\+json}.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6775}{}\doxysection{5.\+0.\+7}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6775}

\begin{DoxyItemize}
\item Fixed\+: JS loader bypasses Node\textquotesingle{}s {\ttfamily require} cache, fixing a bug where updates to {\ttfamily .js} config files would not load even when Cosmiconfig was told not to cache.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6776}{}\doxysection{5.\+0.\+6}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6776}

\begin{DoxyItemize}
\item Fixed\+: Better error message if the end user tries an extension Cosmiconfig is not configured to understand.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6777}{}\doxysection{5.\+0.\+5}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6777}

\begin{DoxyItemize}
\item Fixed\+: {\ttfamily load} and {\ttfamily load\+Sync} work with paths relative to {\ttfamily process.\+cwd()}.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6778}{}\doxysection{5.\+0.\+4}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6778}

\begin{DoxyItemize}
\item Fixed\+: {\ttfamily rc} files with {\ttfamily .js} extensions included in default {\ttfamily search\+Places}.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6779}{}\doxysection{5.\+0.\+3}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6779}

\begin{DoxyItemize}
\item Docs\+: Minor corrections to documentation. {\itshape Released to update package documentation on npm}.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6780}{}\doxysection{5.\+0.\+2}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6780}

\begin{DoxyItemize}
\item Fixed\+: Allow {\ttfamily search\+Sync} and {\ttfamily load\+Sync} to load JS configuration files whose export is a Promise.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6781}{}\doxysection{5.\+0.\+1}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6781}
The API has been completely revamped to increase clarity and enable a very wide range of new usage. {\bfseries{Please read the readme for all the details.}}

While the defaults remain just as useful as before —~and you can still pass no options at all — now you can also do all kinds of wild and crazy things.


\begin{DoxyItemize}
\item The {\ttfamily loaders} option allows you specify custom functions to derive config objects from files. Your loader functions could parse ES2015 modules or Type\+Script, JSON5, even INI or XML. Whatever suits you.
\item The {\ttfamily search\+Places} option allows you to specify exactly where cosmiconfig looks within each directory it searches.
\item The combination of {\ttfamily loaders} and {\ttfamily search\+Places} means that you should be able to load pretty much any kind of configuration file you want, from wherever you want it to look.
\end{DoxyItemize}

Additionally, the overloaded {\ttfamily load()} function has been split up into several clear and focused functions\+:


\begin{DoxyItemize}
\item {\ttfamily search()} now searches up the directory tree, and {\ttfamily load()} loads a configuration file that you don\textquotesingle{}t need to search for.
\item The {\ttfamily sync} option has been replaced with separate synchronous functions\+: {\ttfamily search\+Sync()} and {\ttfamily load\+Sync()}.
\item {\ttfamily clear\+File\+Cache()} and {\ttfamily clear\+Directory\+Cache()} have been renamed to {\ttfamily clear\+Load\+Cache()} and {\ttfamily clear\+Search\+Path()} respectively.
\end{DoxyItemize}

More details\+:


\begin{DoxyItemize}
\item The default JS loader uses {\ttfamily require}, instead of {\ttfamily require-\/from-\/string}. So you {\itshape could} use {\ttfamily require} hooks to control the loading of JS files (e.\+g. pass them through esm or Babel). In most cases it is probably preferable to use a custom loader.
\item The options {\ttfamily rc}, {\ttfamily js}, and {\ttfamily rc\+Extensions} have all been removed. You can accomplish the same and more with {\ttfamily search\+Places}.
\item The default {\ttfamily search\+Places} include {\ttfamily rc} files with extensions, e.\+g. {\ttfamily .thingrc.\+json}, {\ttfamily .thingrc.\+yaml}, {\ttfamily .thingrc.\+yml}. This is the equivalent of switching the default value of the old {\ttfamily rc\+Extensions} option to {\ttfamily true}.
\item The option {\ttfamily rc\+Strict\+Json} has been removed. To get the same effect, you can specify {\ttfamily no\+Ext\+: cosmiconfig.\+load\+Json} in your {\ttfamily loaders} object.
\item {\ttfamily package\+Prop} no longer accepts {\ttfamily false}. If you don\textquotesingle{}t want to look in {\ttfamily package.\+json}, write a {\ttfamily search\+Places} array that does not include it.
\item By default, empty files are ignored by {\ttfamily search()}. The new option {\ttfamily ignore\+Empty\+Search\+Places} allows you to load them, instead, in case you want to do something with empty files.
\item The option {\ttfamily config\+Path} has been removed. Just pass your filepaths directory to {\ttfamily load()}.
\item Removed the {\ttfamily format} option. Formats are now all handled via the file extensions specified in {\ttfamily loaders}.
\end{DoxyItemize}

(If you\textquotesingle{}re wondering with happened to 5.\+0.\+0 ... it was a silly publishing mistake.)\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6782}{}\doxysection{4.\+0.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6782}

\begin{DoxyItemize}
\item Licensing improvement\+: updated {\ttfamily parse-\/json} from {\ttfamily 3.\+0.\+0} to {\ttfamily 4.\+0.\+0}(see \href{https://github.com/sindresorhus/parse-json/pull/12}{\texttt{ sindresorhus/parse-\/json\#12}}).
\item Changed\+: error message format for {\ttfamily JSON} parse errors(see \href{https://github.com/davidtheclark/cosmiconfig/pull/101}{\texttt{ \#101}}). If you were relying on the format of JSON-\/parsing error messages, this will be a breaking change for you.
\item Changed\+: set default for {\ttfamily search\+Path} as {\ttfamily process.\+cwd()} in {\ttfamily explorer.\+load}.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6783}{}\doxysection{3.\+1.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6783}

\begin{DoxyItemize}
\item Added\+: infer format based on file\+Path
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6784}{}\doxysection{3.\+0.\+1}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6784}

\begin{DoxyItemize}
\item Fixed\+: memory leak due to bug in {\ttfamily require-\/from-\/string}.
\item Added\+: for JSON files, append position to end of error message.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6785}{}\doxysection{3.\+0.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6785}

\begin{DoxyItemize}
\item Removed\+: support for loading config path using the {\ttfamily -\/-\/config} flag. cosmiconfig will not parse command line arguments. Your application can parse command line arguments and pass them to cosmiconfig.
\item Removed\+: {\ttfamily argv} config option.
\item Removed\+: support for Node versions $<$ 4.
\item Added\+: {\ttfamily sync} option.
\item Fixed\+: Throw a clear error on getting empty config file.
\item Fixed\+: when a {\ttfamily options.\+config\+Path} is {\ttfamily package.\+json}, return the package prop, not the entire JSON file.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6786}{}\doxysection{2.\+2.\+2}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6786}

\begin{DoxyItemize}
\item Fixed\+: {\ttfamily options.\+config\+Path} and {\ttfamily -\/-\/config} flag are respected.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6787}{}\doxysection{2.\+2.\+0, 2.\+2.\+1}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6787}

\begin{DoxyItemize}
\item 2.\+2.\+0 included a number of improvements but somehow broke stylelint. The changes were reverted in 2.\+2.\+1, to be restored later.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6788}{}\doxysection{2.\+1.\+3}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6788}

\begin{DoxyItemize}
\item Licensing improvement\+: switched from {\ttfamily json-\/parse-\/helpfulerror} to {\ttfamily parse-\/json}.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6789}{}\doxysection{2.\+1.\+2}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6789}

\begin{DoxyItemize}
\item Fixed\+: bug where an {\ttfamily ENOENT} error would be thrown is {\ttfamily search\+Path} referenced a non-\/existent file.
\item Fixed\+: JSON parsing errors in Node v7.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6790}{}\doxysection{2.\+1.\+1}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6790}

\begin{DoxyItemize}
\item Fixed\+: swapped {\ttfamily graceful-\/fs} for regular {\ttfamily fs}, fixing a garbage collection problem.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6791}{}\doxysection{2.\+1.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6791}

\begin{DoxyItemize}
\item Added\+: Node 0.\+12 support.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6792}{}\doxysection{2.\+0.\+2}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6792}

\begin{DoxyItemize}
\item Fixed\+: Node version specified in {\ttfamily package.\+json}.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6793}{}\doxysection{2.\+0.\+1}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6793}

\begin{DoxyItemize}
\item Fixed\+: no more infinite loop in Windows.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6794}{}\doxysection{2.\+0.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6794}

\begin{DoxyItemize}
\item Changed\+: module now creates cosmiconfig instances with {\ttfamily load} methods (see README).
\item Added\+: caching (enabled by the change above).
\item Removed\+: support for Node versions $<$4.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6795}{}\doxysection{1.\+1.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6795}

\begin{DoxyItemize}
\item Add {\ttfamily rc\+Extensions} option.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6796}{}\doxysection{1.\+0.\+2}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6796}

\begin{DoxyItemize}
\item Fix handling of {\ttfamily require()}\textquotesingle{}s within JS module configs.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6797}{}\doxysection{1.\+0.\+1}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6797}

\begin{DoxyItemize}
\item Switch Promise implementation to pinkie-\/promise.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6798}{}\doxysection{1.\+0.\+0}\label{md_sfcode_node_modules_cosmiconfig_CHANGELOG_autotoc_md6798}

\begin{DoxyItemize}
\item Initial release. 
\end{DoxyItemize}