React-native-paper: TextInput type="password" does not seem to work.

Created on 15 Aug 2018  路  1Comment  路  Source: callstack/react-native-paper


Current behaviour


When I render a TextInput component with the "type" prop set to "password", the input text is still visible.

Expected behaviour


I would expect the TextInput to hide the input text with asterixes.

Code sample

            <TextInput type="password" id="password" name="password" label="Password" value={this.state.password} />

Screenshots (if applicable)


screenshot_20180815-220331

What have you tried


Googling for the answer makes it seem like the TextInput component simply does not support this, but this seems unlikely to me.

Any help is greatly appreciated, so thank you in advance!

Your Environment

| software | version
| --------------------- | -------
| android | SDK 26
| react-native | 16.3.1
| react-native-paper | ^1.11.1
| node | v8.11.3
| npm or yarn | 6.1.0

Most helpful comment

hey,
try this:

<TextInput
  secureTextEntry
/>

https://facebook.github.io/react-native/docs/textinput#securetextentry

>All comments

hey,
try this:

<TextInput
  secureTextEntry
/>

https://facebook.github.io/react-native/docs/textinput#securetextentry

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ferrannp picture ferrannp  路  4Comments

scottybo picture scottybo  路  3Comments

tonyxiao picture tonyxiao  路  3Comments

kpervin picture kpervin  路  3Comments

ButuzGOL picture ButuzGOL  路  4Comments