Theme editor

ESX JG Mechanic - Working 100% No errors

  • In FiveM NUI, you cannot use fetch("/api/...") or fetch("http://localhost...").
  • You must use:
  • fetch(`https://${GetParentResourceName()}/callbackName`, { ... })

  • and register a corresponding RegisterNUICallback("callbackName", function(data, cb) ... end) in Lua.
  • The Failed to fetch happens because your UI is asking for something FiveM doesn’t provide (likely /api/... or /web/...). try this if it helps u
 
Back
Top Bottom