flutter text form field number only code example
Example 1: flutter textfield number only
import 'package:flutter/services.dart';
keyboardType: TextInputType.number,
inputFormatters: [FilteringTextInputFormatter.digitsOnly],
Example 2: input only numbers flutter
keyboardType: TextInputType.number