0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Netlify forms で項目を入力必須にする方法

Posted at

Netlify であるかどうかは全く関係なく、HTMLのinputタグの機能として、ブラウザに入力必須であることを示すrequired属性が存在していることが分かりました。

こんな感じで指定すると、

<input type="text" name="name" required>

ブラウザ側でバリデートしてくれました。

↓Google Chrome
Screen Shot 2019-07-03 at 17.54.00.png

↓Firefox

Screen Shot 2019-07-03 at 17.56.36.png

参照:
https://eleventy-netlify-boilerplate.netlify.com/contact/

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?