Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
VasilyStrelyaev committed Jan 3, 2025
1 parent f4223bf commit f427902
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions packages/devextreme-react/src/core/component-base.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ import { elementPropNames, getClassName } from './widget-config';
import { TemplateManager } from './template-manager';
import { ComponentProps } from './component';
import { ElementType, IOptionElement } from './configuration/react/element';
import { IConfigNode } from './configuration/config-node';

import {
NestedOptionContext,
Expand Down Expand Up @@ -97,8 +96,6 @@ const ComponentBase = forwardRef<ComponentBaseRef, any>(

const { parentType } = useContext(NestedOptionContext);

let widgetConfig: IConfigNode;

const childrenContainer = useRef<HTMLDivElement>(null);

const elementDescriptor: IOptionElement = {
Expand All @@ -114,17 +111,14 @@ const ComponentBase = forwardRef<ComponentBaseRef, any>(
props,
};

const options = useOptionScanning(
const [widgetConfig, context] = useOptionScanning(
elementDescriptor,
props.children,
childrenContainer,
Symbol('initial update token'),
'component',
);

[widgetConfig] = options;
const [, context] = options;

const restoreTree = useCallback(() => {
if (childElementsDetached.current && childNodes.current?.length && element.current) {
element.current.append(...childNodes.current);
Expand Down

0 comments on commit f427902

Please sign in to comment.