问题标签 [react-native-vector-icons]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
react-native - 自定义字体图标在 react-native 的框中显示交叉
我正在尝试在本机反应中使用自定义字体。使用 Icomoon 在自定义图标集中转换了 SVG,并尝试了https://www.reactnative.guide/12-svg-icons-using-react-native-vector-icons/12.1-creating-custom-iconset.html中的所有步骤。
react-native-vector-icons
已经安装了。
用于react-native link react-native-vector-icons
设置项目的矢量图标框架。
将 selection.json 和 Icomoon.ttf 文件放在assets/fonts
文件夹中。
并添加 "rnpm": { "assets": [ "resources/fonts" ] }
到 package.json 文件中
创建 CustomIcon.js 文件并添加
在 App.js 文件中添加了以下内容
并且图标在图标位置显示☒。
如果有人有解决方案请分享,谢谢。
react-native - Getting error when installing react native vector icons
I am trying to use react native vector icons in my project, but I getting error when installing it.
Below are the STEPS which I was running on my terminal:
STEP-1 : npm install react-native-elements --save
NO ERROR ON THIS STEP-1
STEP-2: npm install react-native-vector-icons --save
NO ERROR ON THIS STEP-2
STEP-3: react-native link react-native-vector-icons
ERROR:
react-native - React Native 错误 - 无法解析模块`./tab-bar-item-ios`
我刚刚react-native-vector-icons
从 7.1 版升级到 8.0 版......现在我收到以下错误:
我使用 Windows 计算机在真正的 Android 设备上进行测试。有任何想法吗?
javascript - React Native web 故事书 react-native-vector-icons 问题图标
我正在故事书上开发一个反应原生组件,它使用 react-native-paper 和 react-native-vector-icons。
问题是我看不到图标,我尝试按照 react-native-vector-icons 上的指南进行操作,这个:webpack
下面是 webpack,但我不太明白如何使用指南中建议的代码的第二部分,我应该在哪里以及如何使用它。
谁能帮我吗?
网络包:
react-native - 尝试在 vanilla React Native 项目中解决 @expo/vector-icons/FontAwesome 时出错
我今天遇到了这个奇怪的错误:Unable to resolve module `@expo/vector-icons/FontAwesome` from `node_modules/react-native-elements/src/checkbox/CheckBoxIcon.js`: @expo/vector-icons/FontAwesome could not be found within the project.
这个项目不使用 expo,它是使用 vanilla React Native CLI 构建的。我签入了CheckBoxIcon.js
文件,node_modules
但没有看到任何对@expo
. 不确定这是否重要,但在此之前我正在从事一个 xpo 项目,但它不应该影响我正在从事的这个单独的项目,对吗?
我不知道如何解决这个问题,我尝试清除守望者手表,删除 node_modules 并重置 Metro 的缓存。
react-native - React Native - MaterialCommunityIcons 图标名称的打字稿定义
我正在尝试找出 MaterialCommunityIcons 图标名称的类型定义,因为我打算将它用于道具。
reactjs - 反应原生矢量图标 ios 图标不会出现在发布时
我一直在使用 react native 在 ios 上构建一个应用程序,但遇到了一个奇怪的矢量图标问题。当我在调试模式下将应用程序安装到我的手机时,图标不会出现,但是当我重新加载时,它们会出现。
当我将它发布到我的手机和 AppStoreConnect TestFlight 时,图标没有出现。
似乎第一次没有正确加载图标。我有点坚持我应该做什么。这是我到目前为止尝试过的事情的列表:
- 移除节点模块、Pods 和相应的锁定文件并重新安装它们
- 从手机中删除应用程序并重新安装
- 运行
react native link react-native-vector-icons
并重新安装应用程序 - 添加
.tff
s 来复制 Pod 资源并发布 - 添加
.tff
s 到 Copy Bundle Resources 并发布 Icon.loadIcons()
在脚本中尝试过- 将图标列表添加到 info.Plist
我现在没有东西可以尝试了。
有人可以在这里帮忙吗?
ios - node_modules/react-native-vector-icons/lib/create-icon-set.js: #无法克隆
我正在使用“react-native-vector-icons”:“^8.1.0”,我在node_modules/react-native-vector-icons/lib/create-icon-set.js: #<WeakSet> could not be cloned.
iOS 上遇到了这个错误,知道吗?
谢谢!