import * as React from "react"; import * as System from "~/components/system"; import Group from "~/components/system/Group"; import SystemPage from "~/components/system/SystemPage"; import ViewSourceLink from "~/components/system/ViewSourceLink"; import CodeBlock from "~/components/system/CodeBlock"; export default class SystemPageTables extends React.Component { state = { exampleOneOutput: null, exampleOneProps: null, exampleTwoOutput: null, exampleTwoProps: null, }; _handleChange = (e) => this.setState({ [e.target.name]: e.target.value }); render() { return ( Tables

An example of a table component.


Imports

Import React and the TableContent, TableColumn Components.

{`import * as React from 'react'; import { TableContent, TableColumn } from 'slate-react-system';`}

Usage

Declare the Group and Table components.
{`class ExampleOne extends React.Component { state = { exampleOne: null } _handleChange = e => this.setState( { [e.target.name]: e.target.value } ); render() { return( ) } }`}

Output



Accepted React Properties




TableContents

The Table Component has many TableContent properties that can be added to alter the column using the type props.
{`class ExampleTwo extends React.Component { state = { exampleTwo: null } _handleChange = e => this.setState( { [e.target.name]: e.target.value } ); render() { return(
) } }`}

Output



Accepted Type Properties

); } }