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

199
Views
Import not found: getCleanUrl

I try to use MSW with '@web/dev-server' and always get a Uncaught SyntaxError: import not found: getCleanUrl

coming form http://localhost:8000/node_modules/msw/lib/esm/RequestHandler-deps.js

The most minimal example I can come up is:

<script type="module">
        import { setupWorker, rest } from 'msw';
        window.onload = function () {
            const worker = setupWorker(

                rest.get('/test', (req, res, ctx) => {

                    return res(
                        ctx.json({
                           value: 'test',
                        })
                    )
                }),
            )

            worker.start();
        }
    </script>

inside the index.html

The thing is, I can see getCleanUrl inside the browser debugger when I navigate inside the node_modules folder to it.

Also the mockServiceWorker.js is set correctly on the root, I can navigate to it via http://localhost:8000/mockServiceWorker.js

So I am very confused why the browser complains about not finding it..

about 4 years ago · Juan Pablo Isaza
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!