REST or AJAX don't want toolbar |
When I'm building RESTful APIs or just methods that are used by AJAX requests I'm finding the debug toolbar is getting in the way by adding a lot of content to the output. I guess I can always change the .env file to put the site into production mode to prevent this but am I missing any other ways of indicating that is is not required?
AJAX Requests — CodeIgniter 4.1.9 documentation
https://codeigniter4.github.io/userguide.../ajax.html
Thanks for the pointer, if anyone else is using Postman to test API related things, try adding the header X-Requested-With set to XMLHttpRequest and the toolbar won't be returned.
If you're using VS Code you can use the 'thunderclient' extension. Works a treat and you never have to leave the editor, my personal favourite extension after 'VIM'
Practical guide to IgnitedCMS - Book coming soon, www.ignitedcms.com
|
Welcome Guest, Not a member yet? Register Sign In |