Getting Started -> Building a Flow -> Getting Started: Fixed style to have 100 height;
parent
745d8a3a29
commit
310461bd24
13
src/App.tsx
13
src/App.tsx
|
@ -3,19 +3,10 @@ import ReactFlow, { Background, Controls } from 'reactflow';
|
||||||
// we have to import the React Flow styles for it to work
|
// we have to import the React Flow styles for it to work
|
||||||
import 'reactflow/dist/style.css';
|
import 'reactflow/dist/style.css';
|
||||||
|
|
||||||
const nodes = [
|
|
||||||
{
|
|
||||||
id: '1',
|
|
||||||
position: { x: 0, y: 0 },
|
|
||||||
data: { label: 'Hello' },
|
|
||||||
type: 'input',
|
|
||||||
},
|
|
||||||
];
|
|
||||||
|
|
||||||
const Flow = () => {
|
const Flow = () => {
|
||||||
return (
|
return (
|
||||||
<div style={{ height: 800 }}>
|
<div style={{ height: 100 }}>
|
||||||
<ReactFlow nodes={nodes}>
|
<ReactFlow>
|
||||||
<Background />
|
<Background />
|
||||||
<Controls />
|
<Controls />
|
||||||
</ReactFlow>
|
</ReactFlow>
|
||||||
|
|
Loading…
Reference in New Issue