diff --git a/src/util/to-string.js b/src/util/to-string.js index 669b983a..34e9fd5e 100644 --- a/src/util/to-string.js +++ b/src/util/to-string.js @@ -1,7 +1,7 @@ import isBigInt from './is-bigint'; export default function(v) { - return isBigInt(v) - ? (v.toString() + 'n') + return v === undefined ? v + '' + : isBigInt(v) ? v + 'n' : JSON.stringify(v); } \ No newline at end of file