Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

164
Views
how to use fetch to make api calls while building a safari extension

I am working on a safari extension and while using fetch to make a call to an api with the code below:

async function getSomething() {

    try {
        const response  = await fetch("https:// www.xyz.com/abcs/", { # dont mind the space in the URL i created it to be able to post this question
            method: "GET",
            headers: {
                "Content-Type": "application/json",
            },
            mode: "no-cors"
        })
        if (!response.ok) {
            # something is wrong here
        }
    } catch (error) {
        alert(error)
    }
}

I am getting TypeError: Load failed from error above. not sure why and how this is possible because the same code work on chrome extension.

I looked all over the internet and not able to find why would this happen? Does safari require an extra permissions to make webRequest or am i missing something?

about 4 years ago · Santiago Gelvez
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!