TextContent constructor

TextContent(
  1. String key,
  2. dynamic text
)

Implementation

TextContent(String key, dynamic text) : super(key, {}) {
  if (text is String) {
    this.text = text;
  } else {
    this.text = text.toString();
  }
}