npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

quick-request-laravel

v1.2.0

Published

Execute requests easily and quickly to the Laravel backend with QuickRequest, leave Ajax aside, now you have an easy, secure, and modern way of making requests.

Downloads

15

Readme

QuickRequest Laravel

Banner de Quick Request

Introduction

QuickRequest is an ultra-lightweight tool designed for swift and efficient requests to the Laravel backend.

By leveraging the "fetch" mechanism, this solution streamlines the execution of requests to Laravel controllers, eliminating the need for manual assignment of tokens, base URLs, hidden inputs, and other method-specific parameters.

QuickRequest provides a clean and elegant coding experience, making it a pleasant shift for developers accustomed to older technologies like Ajax.

Tailored to meet specific requirements, QuickRequest offers essential features for easily managing various request types in a standard Laravel application, including GET, POST, PUT, PATCH, and DELETE.

Additionally, it offers a convenient approach for efficient file downloads by effectively handling Blobs.

Forget about writing extra lines of code—experience the minimalist style of QuickRequest.

Documentation

📖📖📖 FULL DOCUMENTATION 📖📖📖

Installation

In order to utilize this tool, you need to have the csrf-token meta tag in your main template, as per the official Laravel documentation on X-CSRF-TOKEN. This value will be independently read by the QuickRequest package, so you should NOT include the @csrf directives in your forms or create hidden inputs with this value, as the library handles it for you.

<meta name="csrf-token" content="{{ csrf_token() }}">

CDN Usage

If you're not using VITE in your project, you can install this solution simply by utilizing the CDN available for your use.

It's as easy as adding the following line of code to the <head> section of your main template.

<head>
    <!-- ... -->
    <script src="https://cdn.jsdelivr.net/gh/rmunate/Quick-Request-Laravel/dist/js/quick-request.min.js"></script>
    <!-- ... -->
</head>

Alternatively, you could download the content from the aforementioned URL, place it in the public directory within a js folder, keeping the code locally in your project. However, this means you would maintain code that won't be updated with the adjustments or enhancements applied to the project.

<head>
    <!-- ... -->
    <script src="{{ asset('js/quick-request.min.js') }}"></script>
    <!-- ... -->
</head>

NPM Usage with VITE

If you're developing your project with VITE, it will be much more convenient to install this solution using the following command.

npm i quick-request-laravel

This way, the package will be readily available in your system; you just need to import it into your modules.

import { QuickRequest } from 'quick-request-laravel';

License

This project is under the MIT License.

🌟 Support My Projects! 🚀

Become a Sponsor

Make any contributions you see fit; the code is entirely yours. Together, we can do amazing things and improve the world of development. Your support is invaluable. ✨

If you have ideas, suggestions, or just want to collaborate, we are open to everything! Join our community and be part of our journey to success! 🌐👩‍💻👨‍💻