Closed harikt closed 11 years ago
The doc needs to be corrected for the way setField
works. The second argument should be hidden
and need to use setAttribs
I don't know whether it is a good idea not to throw the exception at all, if there is no field ? or whether hasField
itself is good .
This apparently exists already in the form of __isset($input_name).
Hi, __isset($input_name) checks if a value is set on an input (it returns false if a field exists but has no value set), I think we are missing a hasField() method, what do you think?
It will be good to have
hasField
method for when we are adding aAntoCsrf
class, if it is not authenticated the field__csrf_token
will not be added and it will thow an exceptionUncaught exception 'Aura\Input\Exception\NoSuchInput' with message '__csrf_token'