react-native-paper 3.0.0-alpha.3
The add icon is showing up as a question mark, and I get a Yellowbox warning "Failed prop type: Invalid prop 'name' of value 'add' supplied to 'Icon' expected on of [...]. Reverting to 3.0.0-alpha.2 resolved the issue.
import React, {Component} from 'react';
import { FAB } from 'react-native-paper';
import FontAwesome5 from 'react-native-vector-icons/FontAwesome5';
class HomeFAB extends React.Component {
constructor(props) {
super(props);
this.state = { open: false };
}
render() {
return <FAB.Group open={this.state.open} icon="add" actions={[{
icon: (props) => <FontAwesome5 name="comments" {...props} />,
label: 'New Chat',
onPress: () => console.log('press'),
}]}
onStateChange={({ open }) => this.setState({ open })} />
}
}
They have switched to MaterialCommunityIcons for more icons + outlined. You have to look at this website for icons now
https://materialdesignicons.com/
'add' is now 'plus'
Most helpful comment
They have switched to MaterialCommunityIcons for more icons + outlined. You have to look at this website for icons now
https://materialdesignicons.com/
'add' is now 'plus'