x
1
2
3
4
5
6
7
<form class="usa-form" id="new_text_area_component_preview_article" action="#" accept-charset="UTF-8" method="post"><input type="hidden" name="authenticity_token" value="9QokTWTxCIX1U7OJBoCsDtbfqWSYsbc1O0WKRjXeTk4AKKuZlEuUnO3zXduTvXn7Z4BTTy93i_D96k5tPw2v4A" autocomplete="off" />
<div class=''>
<label class="usa-label" for="text_area_component_preview_article_body">Body</label>
<textarea class="usa-textarea" name="text_area_component_preview_article[body]" id="text_area_component_preview_article_body">
</textarea>
</div>
</form>
1
2
3
4
5
6
7
8
9
-# haml-lint:disable LineLength
- article = UswdsComponents::TextAreaComponentPreview::Article.new(body: params[:value])
-# haml-lint:enable LineLength
- article.errors.add(:body, params[:error1]) if params[:error1].present?
- article.errors.add(:body, params[:error2]) if params[:error2].present?
= form_for article, url: '#', html: { class: 'usa-form' } do |f|
= render UswdsComponents::TextAreaComponent.new(form: f, attribute: :body)
Param Description Input