Skip to content

Commit b20c581

Browse files
committed
fix docstrings in normalize.ts and normalization tests
1 parent 5b328bf commit b20c581

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

packages/utils/src/normalize.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ type ObjOrArray<T> = { [key: string]: T };
2828
* @param input The object to be normalized.
2929
* @param depth The max depth to which to normalize the object. (Anything deeper stringified whole.)
3030
* @param maxProperties The max number of elements or properties to be included in any single array or
31-
* object in the normallized output..
31+
* object in the normallized output.
3232
* @returns A normalized version of the object, or `"**non-serializable**"` if any errors are thrown during normalization.
3333
*/
3434
// eslint-disable-next-line @typescript-eslint/no-explicit-any

packages/utils/test/normalize.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ describe('normalize()', () => {
184184
});
185185
});
186186

187-
describe('dont mutate and skip non-enumerables', () => {
187+
describe("doesn't mutate the given object and skips non-enumerables", () => {
188188
test('simple object', () => {
189189
const circular = {
190190
foo: 1,
@@ -311,7 +311,7 @@ describe('normalize()', () => {
311311
});
312312
});
313313

314-
describe('changes unserializeable/global values/classes to its string representation', () => {
314+
describe('changes unserializeable/global values/classes to their respective string representations', () => {
315315
test('primitive values', () => {
316316
expect(normalize(undefined)).toEqual('[undefined]');
317317
expect(normalize(NaN)).toEqual('[NaN]');
@@ -376,7 +376,7 @@ describe('normalize()', () => {
376376
});
377377
});
378378

379-
test('known Classes like Reacts SyntheticEvents', () => {
379+
test("known classes like React's `SyntheticEvent`", () => {
380380
const obj = {
381381
foo: {
382382
nativeEvent: 'wat',
@@ -510,7 +510,7 @@ describe('normalize()', () => {
510510
});
511511
});
512512

513-
test('normalizes value on every iteration of decycle and takes care of things like Reacts SyntheticEvents', () => {
513+
test("normalizes value on every iteration of decycle and takes care of things like React's `SyntheticEvent`", () => {
514514
const obj = {
515515
foo: {
516516
nativeEvent: 'wat',

0 commit comments

Comments
 (0)