[#108] replace assign-deep with loadash/merge

This commit is contained in:
Bartłomiej Głownia 2022-03-29 13:55:44 +02:00
parent 7e74615bf6
commit a68bce9ed1
2 changed files with 3 additions and 3 deletions

View File

@ -1,6 +1,6 @@
import { useRef, useCallback, useMemo } from 'react';
import { produce } from 'immer';
import assign from 'assign-deep';
import merge from 'lodash/merge';
import { useRouter } from 'next/router';
import { AsyncRenderer } from '../../components/async-renderer';
import { PositionsTable, getRowNodeId } from '@vegaprotocol/positions';
@ -31,7 +31,7 @@ export const Positions = () => {
const updatedData = produce<positions_party_positions>(
rowNode.data,
(draft: positions_party_positions) => {
assign(draft, delta);
merge(draft, delta);
}
);
if (updatedData !== rowNode.data) {

View File

@ -1,7 +1,7 @@
import { forwardRef, useMemo } from 'react';
import type { ValueFormatterParams } from 'ag-grid-community';
import {
PriceCell /*, MarginCell*/,
PriceCell,
formatNumber,
volumePrefix,
addDecimal,