How to use the react-native-vector-icons/Ionicons.propTypes function in react-native-vector-icons

To help you get started, we’ve selected a few react-native-vector-icons examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github 99xt / first-born / src / atoms / Icon.js View on Github external
Platform.OS === "android" ? "md-" + name : "ios-" + name
                    }
                    size={size}
                    color={color}
                    {...otherProps}
                />
            );
        }
        return (
            
        );
    }
}

Icon.propTypes = {
    ...Ionicon.propTypes,
    name: PropTypes.string
};

Icon.defaultProps = {
    color: commonColors.white,
    size: 18
};
github GeekyAnts / NativeBase / src / backward / Widgets / Icon.js View on Github external
this.Icon = Ionicons;
      }
    } else {
      this.Icon = Ionicons;
    }
  }

  render() {
    return (
       this._root = c} {...this.props} />
    );
  }
}

Icon.propTypes = {
  ...Ionicons.propTypes,
  style: React.PropTypes.object,
};

const StyledIcon = connectStyle('NativeBase.Icon', {}, mapPropsToStyleNames)(Icon);

export {
  StyledIcon as Icon,
};