反应bootstrap形式textarea行高

时间:2019-05-03 09:39:50

标签: css reactjs react-bootstrap

我正试图使我的文本区域以行高识别显示。我遵循了此板上的一些建议。

我目前从react-bootstrap导入componentClass,在我的表单字段中,我有:

<div className="form-group">
  <label htmlFor="overview">Outline your proposal</label>
  <Field
    name="overview"
    componentClass="textarea"
    rows={4}
    className={
      "form-control" +
      (errors.overview && touched.overview ? " is-invalid" : "")
    }
  />
  <ErrorMessage name="overview" component="div" className="invalid-feedback" />
</div>

它仍然在一行中呈现。

使此功能与文本区域的行号一起使用的隐藏秘密是什么?

0 个答案:

没有答案