Skip to content

[Bug]: 'flash-off-outline' icon not working on iOS #1789

@lakshit-acv

Description

@lakshit-acv

Which package are you using?

@react-native-vector-icons/*

What platform(s) does this occur on?

iOS

What happened?

So I already have an existing old react-native-vector-icons library, but I installed @react-native-vector-icons/material-design-icons because I needed some icons which were specifically present in the material design library. The icon named as 'flash-off-outline' which is a part of the material design icons, is not visible correctly on iOS environment. A question mark enclosed in a square (which is possibly what a default icon is for an unknown name icon) is displayed in the screen instead. I want to understand what could be possible causing the issue ?

Relevant log output

Consumer file (using styled components)
<TorchContainer testID="torch-button" onPress={onTorchPressed}>
  <TorchIcon name={torch ? "flash-outline" : "flash-off-outline"} size={24} />
</TorchContainer>

TorchIcon file (styles.js)
import Icon from "@react-native-vector-icons/material-design-icons";
// import MaterialDesignIcons from "@react-native-vector-icons/material-design-icons";
// import Icon from "react-native-vector-icons/MaterialIcons";
import styled from "styled-components/native";
import { TouchableWithoutFeedback } from "react-native-gesture-handler";
import styles from "@styles";

export const TorchContainer = styled(TouchableWithoutFeedback)`
  margin: ${styles.dimensions.spacing_m_01};
  height: 30px;
  width: 30px;
`;

export const TorchIcon = styled(Icon)`
  color: ${({ theme }) => theme.secondary};
`;

Minimal reproducible example

Please ignore the yellow color that is intentional and not related to the issue
Image

Your computer environment

System:
  OS: macOS 15.5
  CPU: (16) arm64 Apple M4 Max
  Memory: 274.47 MB / 64.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 20.9.0
    path: ~/.nvm/versions/node/v20.9.0/bin/node
  Yarn:
    version: 3.6.4
    path: /opt/homebrew/bin/yarn
  npm:
    version: 10.1.0
    path: ~/.nvm/versions/node/v20.9.0/bin/npm
  Watchman:
    version: 2025.03.03.00
    path: /opt/homebrew/bin/watchman
Managers:
  CocoaPods:
    version: 1.16.2
    path: /opt/homebrew/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 24.2
      - iOS 18.2
      - macOS 15.2
      - tvOS 18.2
      - visionOS 2.2
      - watchOS 11.2
  Android SDK:
    API Levels:
      - "31"
      - "33"
      - "34"
      - "35"
    Build Tools:
      - 33.0.0
      - 34.0.0
      - 35.0.0
      - 36.0.0
    System Images:
      - android-29 | Google Play ARM 64 v8a
      - android-35 | Google Play ARM 64 v8a
    Android NDK: Not Found
IDEs:
  Android Studio: 2024.3 AI-243.26053.27.2432.13536105
  Xcode:
    version: 16.2/16C5032a
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 19.0.2
    path: /usr/bin/javac
  Ruby:
    version: 2.6.10
    path: /usr/bin/ruby
npmPackages:
  "@react-native-community/cli": Not Found
  react:
    installed: 18.3.1
    wanted: ^18.3.1
  react-native:
    installed: 0.75.3
    wanted: 0.75.3
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: false
iOS:
  hermesEnabled: true
  newArchEnabled: false

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions