RealGrid2 Tutorial
React Component Tutorial
Set options

Apply grid, provider options

The gridView option is specified in gridProps, and the provider option can be applied to dataProps as follows. For gridView option settings, refer to gridView options (opens in a new tab), For provider option settings, refer to provider options (opens in a new tab).

import {RGDataField, RGDataColumn, RealGridReact } from "realgrid-react"
 
const App = () => {
    const gridRef = useRef<RealGridReact>(null);
 
    return (
        <div style={{width:"100%", height: "550px"}}>
            <RealGridReact 
              ref={gridRef}
              rows={[
                {field1:"컬럼1데이터",field2:"컬럼2데이터"},
                {field1:"컬럼1데이터",field2:"컬럼2데이터"}
              ]}
              gridProps={{
                edit:{commitByCell: true},
                groupPanel:{visible: true}
              }}
              dataProps={{softDeleting:true}}
            >
                <RGDataField fieldName="field1"/>
                <RGDataField fieldName="field2"/>
                <RGDataColumn name="field1" fieldName="field1" width={200}/>
                <RGDataColumn name="field2" fieldName="field2"/>
            </RealGridReact>
        </div>    
    )
}
 
export default App