Skip to content

Instantly share code, notes, and snippets.

@nattatorn-dev
Last active November 8, 2017 05:19
Show Gist options
  • Save nattatorn-dev/348ea1f52460a36e3712cc93c8d437d4 to your computer and use it in GitHub Desktop.
Save nattatorn-dev/348ea1f52460a36e3712cc93c8d437d4 to your computer and use it in GitHub Desktop.
static propTypes = {
data: PropTypes.array.isRequired,
title: PropTypes.string.isRequired,
len: PropTypes.number,
keyName: PropTypes.string.isRequired,
showLess: PropTypes.bool.isRequired,
containerStlye: PropTypes.object,
children: PropTypes.node,
}
static defaultProps = {
len: 4,
showLess: false,
containerStlye: {},
}
static async getInitialProps({ req }) {
const initialInput = getInitialInput(req);
return { initialInput };
}
static Throttle = 1000;
static DefaultOutput = "";
static DefaultLogger = [];
state = {
input: this.props.initialInput,
output: "",
logger: Editor.DefaultLogger,
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment