Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/ionic-framework/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ionic framework 无法读取属性';图标';未定义的_Ionic Framework_Leaflet_Font Awesome - Fatal编程技术网

Ionic framework 无法读取属性';图标';未定义的

Ionic framework 无法读取属性';图标';未定义的,ionic-framework,leaflet,font-awesome,Ionic Framework,Leaflet,Font Awesome,我的错误与这里提到的相同 . 我是爱奥尼亚的新手,这是我第一次使用Leavet令人敬畏的标记 我尝试过这个解决方案,但没有成功 index.html: <link rel="stylesheet" href="https://unpkg.com/leaflet@1.6.0/dist/leaflet.css" integrity="sha512-xwE/Az9zrjBIphAcBb3F6JVqxf46+CDLwfLMHloNu6KEQCAWi6HcDUbeOfBIptF7tcCzus

我的错误与这里提到的相同 . 我是爱奥尼亚的新手,这是我第一次使用Leavet令人敬畏的标记

我尝试过这个解决方案,但没有成功

index.html:

<link rel="stylesheet" href="https://unpkg.com/leaflet@1.6.0/dist/leaflet.css"
    integrity="sha512-xwE/Az9zrjBIphAcBb3F6JVqxf46+CDLwfLMHloNu6KEQCAWi6HcDUbeOfBIptF7tcCzusKFjFw2yuvEpDL9wQ=="
    crossorigin="" />

  <link rel="stylesheet" href="assets/leaflet/leaflet.awesome-markers.css">

<script src="https://unpkg.com/leaflet@1.6.0/dist/leaflet.js"
    integrity="sha512-gZwIG9x3wUXg2hdXF6+rVkLF/0Vi9U8D2Ntg4Ga5I5BZpVkVxlJWbSQtXPSiUTtC0TjtGOmxa1AJPuV0CPthew=="
    crossorigin=""></script>

任何帮助都将不胜感激

您必须在html中添加
传单.awesome markers.js

<script src="https://cdnjs.cloudflare.com/ajax/libs/Leaflet.awesome-markers/2.0.0/leaflet.awesome-markers.min.js"></script>

您必须在html中添加
传单.awesome markers.js

<script src="https://cdnjs.cloudflare.com/ajax/libs/Leaflet.awesome-markers/2.0.0/leaflet.awesome-markers.min.js"></script>

谢谢你的帮助,不幸的是我还是会犯错误。谢谢你的帮助,不幸的是我还是会犯错误。
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.11.2/css/all.css" integrity="sha256-46qynGAkLSFpVbEBog43gvNhfrOj+BmwXdxFgVK/Kvc=" crossorigin="anonymous" />
var redMarker = L.AwesomeMarkers.icon({
      icon: 'coffee',
      markerColor: 'red',
      prefix: 'fa'
    });

    L.marker([this.lat, this.lng], {icon: redMarker}).addTo(this.map);