\begin{quote}
Check if stdout or stderr is \href{https://unix.stackexchange.com/a/43389/7678}{\texttt{ interactive}} \end{quote}
It checks that the stream is \href{https://jameshfisher.com/2017/12/09/what-is-a-tty/}{\texttt{ TTY}}, not a dumb terminal, and not running in a CI.

This can be useful to decide whether to present interactive UI or animations in the terminal.\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13131}{}\doxysection{Install}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13131}

\begin{DoxyCode}{0}
\DoxyCodeLine{\$ npm install is-\/interactive }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13132}{}\doxysection{Usage}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13132}

\begin{DoxyCode}{0}
\DoxyCodeLine{const isInteractive = require('is-\/interactive');}
\DoxyCodeLine{}
\DoxyCodeLine{isInteractive();}
\DoxyCodeLine{//=> true }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13133}{}\doxysection{API}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13133}
\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13134}{}\doxysubsection{is\+Interactive(options?)}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13134}
\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13135}{}\doxysubsubsection{options}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13135}
Type\+: {\ttfamily object}\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13136}{}\doxyparagraph{stream}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13136}
Type\+: \href{https://nodejs.org/api/stream.html\#stream_class_stream_writable}{\texttt{ {\ttfamily stream.\+Writable}}}~\newline
 Default\+: \href{https://nodejs.org/api/process.html\#process_process_stdout}{\texttt{ {\ttfamily process.\+stdout}}}

The stream to check.\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13137}{}\doxysection{FAQ}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13137}
\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13138}{}\doxysubsubsection{Why are you not using $<$a href=\char`\"{}https\+://github.\+com/watson/ci-\/info\char`\"{}$>$$<$tt$>$ci-\/info$<$/tt$>$$<$/a$>$ for the CI check?}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13138}
It\textquotesingle{}s silly to have to detect individual CIs. They should identify themselves with the {\ttfamily CI} environment variable, and most do just that. A manually maintained list of detections will easily get out of date. And if a package using {\ttfamily ci-\/info} doesn\textquotesingle{}t update to the latest version all the time, they will not support certain CIs. It also creates unpredictability as you might assume a CI is not supported and then suddenly it gets supported and you didn\textquotesingle{}t account for that. In addition, some of the manual detections are loose and might cause false-\/positives which could create hard-\/to-\/debug bugs.\hypertarget{md_sfcode_node_modules_is_interactive_readme_autotoc_md13139}{}\doxysubsubsection{Why does this even exist? It\textquotesingle{}s just a few lines.}\label{md_sfcode_node_modules_is_interactive_readme_autotoc_md13139}
It\textquotesingle{}s not about the number of lines, but rather discoverability and documentation. A lot of people wouldn\textquotesingle{}t even know they need this. Feel free to copy-\/paste the code if you don\textquotesingle{}t want the dependency. You might also want to read \href{https://blog.sindresorhus.com/small-focused-modules-9238d977a92a}{\texttt{ this blog post}}. 