我正在開發 Vue 3 應用程式,我在 sass 中使用 SVG 代碼作為背景 URL。
$bg-image: url("data:image/svg xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 11'><path fill='#{$color}' d='M4.89557 6.49823L2.79487 4.26513C2.26967 3.70683 1.38251 3.70683 0.857309 4.26513C0.375593 4.77721 0.375593 5.57574 0.857309 6.08781L4.74989 10.2257C5.14476 10.6455 5.81176 10.6455 6.20663 10.2257L13.1427 2.85252C13.6244 2.34044 13.6244 1.54191 13.1427 1.02984C12.6175 0.471537 11.7303 0.471536 11.2051 1.02984L6.06096 6.49823C5.74506 6.83403 5.21146 6.83403 4.89557 6.49823Z'/></svg>");
到目前為止一切正常,但是當我更新 vue 版本 一些額外的 vue 相關依賴項,如 vuex、eslint-plugin-vue 等。
npm run serve專案服務正確,但我開始在我的代碼中收到以下警告。
warning in data:image/svg xml,
There are multiple modules with names that only differ in casing.
This can lead to unexpected behavior when compiling on a filesystem with other case-semantic.
Use equal casing. Compare these module identifiers:
uj5u.com熱心網友回復:
改變十六進制顏色顯然解決了這個問題#FFFFFF。#ffffff
轉載請註明出處,本文鏈接:https://www.uj5u.com/ruanti/443681.html
