'Problem with parameter of fetch() in TypeScript

I created small application using ASP.NET 6.0 and React+Redux. I created Controller with name "ToursController" and use fetch(`tours`) inside Tours.ts store to fetch data from ToursController. But Tours.ts converted into Tours.js with fetch("tour"). So I have 404 Not found. Why fetch(`tours`) in TypeScript converted into fetch("tour")? And how can I get away it?



Solution 1:[1]

It's magic, but I changed fetch(`tours`) to fetch('tours') in the TypeScript code and all work fine.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Jeremy Caney