string representations of objects in node and the browser

\href{https://travis-ci.com/inspect-js/object-inspect}{\texttt{ }}\hypertarget{md_sfcode_node_modules_object_inspect_readme_autotoc_md18805}{}\doxysection{example}\label{md_sfcode_node_modules_object_inspect_readme_autotoc_md18805}
\hypertarget{md_sfcode_node_modules_object_inspect_readme_autotoc_md18806}{}\doxysubsection{circular}\label{md_sfcode_node_modules_object_inspect_readme_autotoc_md18806}

\begin{DoxyCode}{0}
\DoxyCodeLine{var inspect = require('object-\/inspect');}
\DoxyCodeLine{var obj = \{ a: 1, b: [3,4] \};}
\DoxyCodeLine{obj.c = obj;}
\DoxyCodeLine{console.log(inspect(obj)); }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_object_inspect_readme_autotoc_md18807}{}\doxysubsection{dom element}\label{md_sfcode_node_modules_object_inspect_readme_autotoc_md18807}

\begin{DoxyCode}{0}
\DoxyCodeLine{var inspect = require('object-\/inspect');}
\DoxyCodeLine{}
\DoxyCodeLine{var d = document.createElement('div');}
\DoxyCodeLine{d.setAttribute('id', 'beep');}
\DoxyCodeLine{d.innerHTML = '<b>wooo</b><i>iiiii</i>';}
\DoxyCodeLine{}
\DoxyCodeLine{console.log(inspect([ d, \{ a: 3, b : 4, c: [5,6,[7,[8,[9]]]] \} ])); }

\end{DoxyCode}


output\+:


\begin{DoxyCode}{0}
\DoxyCodeLine{[ <div id="{}beep"{}>...</div>, \{ a: 3, b: 4, c: [ 5, 6, [ 7, [ 8, [ ... ] ] ] ] \} ] }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_object_inspect_readme_autotoc_md18808}{}\doxysection{methods}\label{md_sfcode_node_modules_object_inspect_readme_autotoc_md18808}

\begin{DoxyCode}{0}
\DoxyCodeLine{var inspect = require('object-\/inspect') }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_object_inspect_readme_autotoc_md18809}{}\doxysubsection{var s = inspect(obj, opts=\{\})}\label{md_sfcode_node_modules_object_inspect_readme_autotoc_md18809}
Return a string {\ttfamily s} with the string representation of {\ttfamily obj} up to a depth of {\ttfamily opts.\+depth}.

Additional options\+:
\begin{DoxyItemize}
\item {\ttfamily quote\+Style}\+: must be \char`\"{}single\char`\"{} or \char`\"{}double\char`\"{}, if present. Default `\textquotesingle{}single'{\ttfamily for strings,}\textquotesingle{}double\textquotesingle{}{\ttfamily for HTML elements. -\/}max\+String\+Length{\ttfamily \+: must be}0{\ttfamily , a positive integer,}Infinity{\ttfamily , or}null{\ttfamily , if present. Default}Infinity{\ttfamily . -\/}custom\+Inspect{\ttfamily \+: When}true{\ttfamily , a custom inspect method function will be invoked. Default}true{\ttfamily . -\/}indent{\ttfamily \+: must be \char`\"{}\textbackslash{}t\char`\"{},}null{\ttfamily , or a positive integer. Default}null\`{}.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_object_inspect_readme_autotoc_md18810}{}\doxysection{install}\label{md_sfcode_node_modules_object_inspect_readme_autotoc_md18810}
With \href{https://npmjs.org}{\texttt{ npm}} do\+:


\begin{DoxyCode}{0}
\DoxyCodeLine{npm install object-\/inspect }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_object_inspect_readme_autotoc_md18811}{}\doxysection{license}\label{md_sfcode_node_modules_object_inspect_readme_autotoc_md18811}
MIT 