OiO.lk Community platform!

Oio.lk is an excellent forum for developers, providing a wide range of resources, discussions, and support for those in the developer community. Join oio.lk today to connect with like-minded professionals, share insights, and stay updated on the latest trends and technologies in the development field.
  You need to log in or register to access the solved answers to this problem.
  • You have reached the maximum number of guest views allowed
  • Please register below to remove this limitation

I am getting chrome://invalid when I use __MSG_@@extension_id__ in my CSS file

  • Thread starter Thread starter Aditya Krishna
  • Start date Start date
A

Aditya Krishna

Guest
I am building a chrome extension with Manifest V3. I am using the below-given snippet in my CSS file to load local fonts.

Code:
@font-face {
    font-family: 'PoppinsLight';
    src: url('chrome-extension://__MSG_@@extension_id__/assets/Fonts/Poppins-Light.ttf');
}

When I load it into my browser, I get this error

Code:
Request URL: chrome-extension://invalid/
Referrer Policy: strict-origin-when-cross-origin

I have also added web_accessible_resources in my Manifest. So, no problem at that end.

I would really appreciate some help. Thanks!

<p>I am building a chrome extension with <code>Manifest V3</code>. I am using the below-given snippet in my CSS file to load local fonts.</p>
<pre><code>@font-face {
font-family: 'PoppinsLight';
src: url('chrome-extension://__MSG_@@extension_id__/assets/Fonts/Poppins-Light.ttf');
}
</code></pre>
<p>When I load it into my browser, I get this error</p>
<pre><code>Request URL: chrome-extension://invalid/
Referrer Policy: strict-origin-when-cross-origin
</code></pre>
<p>I have also added <code>web_accessible_resources</code> in my Manifest. So, no problem at that end.</p>
<p>I would really appreciate some help. Thanks!</p>
 

Latest posts

Top