I need help refactoring my http request
I want to be able to call the function anywhere. I would like to seperate services. I dont like how I am using services to make an http call.
8 Replies
you can just inject that service and use that method anywhere
Can you use $paste so mobile may view your code more easily?
If your code is too long, you can post to https://paste.mod.gg/, save, and copy the link into chat for others to see your shared code!
BlazeBin - unolvxlretmv
A tool for sharing your source code with the world!
I agree with https://discord.com/channels/143867839282020352/1257776569309466755/1257804863442522162
Create a service for your functionality, register to DI and inject where needed
blueberriesiftheywerecats
you can just inject that service and use that method anywhere
Quoted by
<@293455315465273344> from #I need help refactoring my http request (click here)
React with ❌ to remove this embed.
What issue do you see with making http requests via a service?