Skip to content

Instantly share code, notes, and snippets.

View jerearaujo03's full-sized avatar

Jeremias Araujo jerearaujo03

  • 03:28 (UTC -03:00)
View GitHub Profile
@JeffreyWay
JeffreyWay / laravel.js
Last active October 9, 2024 03:43
Want to send a DELETE request when outside of a form? This will handle the form-creation bits for you dynamically, similar to the Rails implementation. (Requires jQuery, but doesn't have to.) To use, import script, and create a link with the `data-method="DELETE"` attribute.
/*
<a href="posts/2" data-method="delete"> <---- We want to send an HTTP DELETE request
- Or, request confirmation in the process -
<a href="posts/2" data-method="delete" data-confirm="Are you sure?">
*/
(function() {
@ivanvermeyen
ivanvermeyen / !NOTE.md
Last active March 15, 2023 05:25
Setup a Laravel Storage driver with Google Drive API