When using vue cli 3, I encountered an issue with a font file in my project. Specifically, I have a file named fonts.scss where I include the following code:
@font-face {
font-family: 'ElMessiri';
src: url('./fonts/ElMessiri/ElMessiri-VariableFont_wght.ttf') format(' truetype');
font-weight: 700;
font-style: normal;
}
To use this font in components, I imported it like so:
<style lang="scss" scoped>
@import "../css/Main.scss";
@import "../css/font.scss";
</style>
Despite the font file being available, I encountered the following error message:
- @/fonts/ElMessiri/ElMessiri-VariableFont_wght.ttf in