@brillout/json-serializer 0.5.1 → 0.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/stringify.js +1 -1
- package/dist/esm/stringify.js +1 -1
- package/package.json +9 -7
- package/index.js +0 -1
package/dist/cjs/stringify.js
CHANGED
|
@@ -48,7 +48,7 @@ function stringify(value, { forbidReactElements, space, valueName = 'value', sor
|
|
|
48
48
|
const name = valName ? ' `' + valName + '`' : '';
|
|
49
49
|
const location = path.length === 0 ? '' : ` ${name ? 'at ' : ''}\`${valueName}[${path.map((p) => `'${p}'`).join('][')}]\``;
|
|
50
50
|
const fallback = name === '' && location === '' ? ` ${valueName}` : '';
|
|
51
|
-
return `Cannot serialize${name}${location}${fallback} because it is a ${valueType} (https://github.com/brillout/json-
|
|
51
|
+
return `Cannot serialize${name}${location}${fallback} because it is a ${valueType} (https://github.com/brillout/json-serializer)`;
|
|
52
52
|
}
|
|
53
53
|
}
|
|
54
54
|
exports.stringify = stringify;
|
package/dist/esm/stringify.js
CHANGED
|
@@ -46,6 +46,6 @@ function stringify(value, { forbidReactElements, space, valueName = 'value', sor
|
|
|
46
46
|
const name = valName ? ' `' + valName + '`' : '';
|
|
47
47
|
const location = path.length === 0 ? '' : ` ${name ? 'at ' : ''}\`${valueName}[${path.map((p) => `'${p}'`).join('][')}]\``;
|
|
48
48
|
const fallback = name === '' && location === '' ? ` ${valueName}` : '';
|
|
49
|
-
return `Cannot serialize${name}${location}${fallback} because it is a ${valueType} (https://github.com/brillout/json-
|
|
49
|
+
return `Cannot serialize${name}${location}${fallback} because it is a ${valueType} (https://github.com/brillout/json-serializer)`;
|
|
50
50
|
}
|
|
51
51
|
}
|
package/package.json
CHANGED
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@brillout/json-serializer",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.2",
|
|
4
4
|
"description": "Same as JSON but with added support for `Date`, `undefined`, `Map`, `Set`, and more.",
|
|
5
|
-
"main": "./index.
|
|
5
|
+
"main": "./index.mjs",
|
|
6
6
|
"exports": {
|
|
7
|
-
".": "./index.
|
|
7
|
+
".": "./index.mjs",
|
|
8
8
|
"./parse": {
|
|
9
|
-
"
|
|
10
|
-
"
|
|
9
|
+
"worker": "./dist/cjs/parse.js",
|
|
10
|
+
"node": "./dist/cjs/parse.js",
|
|
11
|
+
"browser": "./dist/esm/parse.js"
|
|
11
12
|
},
|
|
12
13
|
"./stringify": {
|
|
13
|
-
"
|
|
14
|
-
"
|
|
14
|
+
"worker": "./dist/cjs/stringify.js",
|
|
15
|
+
"node": "./dist/cjs/stringify.js",
|
|
16
|
+
"browser": "./dist/esm/stringify.js"
|
|
15
17
|
}
|
|
16
18
|
},
|
|
17
19
|
"scripts": {
|
package/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
throw new Error("Module `@brillout/json-serializer` doesn't exist anymore: load `@brillout/json-serializer/parse` and `@brillout/json-serializer/stringify` instead.")
|