Download the PHP package lao9s/livewire-modal-twitter without Composer

On this page you can find all versions of the php package lao9s/livewire-modal-twitter. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package livewire-modal-twitter

About Livewire Modal Twitter

Livewire component that provides a modal like on Twitter. Also, it supports images gallery with content or without.

Installation

To get started, require the package via Composer:

Livewire directive

Add the Livewire directive @livewire('livewire-modal-twitter') and also the Javascript @livewireModalTwitterScript directive to your template.

Next you will need to publish the required scripts with the following command:

Alpine

Livewire Modal Twitter requires Alpine. You can use the official CDN to quickly include Alpine:

TailwindCSS

This modal is made with TailwindCSS. You can use the official CDN to quickly include TailwindCSS:

If you use a different CSS framework I recommend that you publish the modal templates and change the markup to include the required classes for your CSS framework.

Creating modal

You can run php artisan make:livewire ShowPost to make the initial Livewire component. Open your component class and make sure it extends the ModalTwitterComponent class:

If you need to load data inside of your livewire component, you need to use method dispatch() instead mount(), also for display preloading you has in hasLoading() return to true:

Blade

In your blade Livewire component show-post.blade.php, you has to use standard laravel component livewire-modal-twitter::dialog:

Opening a modal

To open a modal you will need to emit an event. To open the ShowPost modal for example:

Passing parameters

You can pass parameters like images or post_id:

The parameters are passed to the mount method on the modal component:

Security

If you are new to Livewire, I recommend to take a look at the security details. In short, it's very important to validate all information given Livewire stores this information on the client-side, or in other words, this data can be manipulated.

Credits

License

Livewire Modal Twitter is open-sourced software licensed under the MIT license.


All versions of livewire-modal-twitter with dependencies

PHP Build Version
Package Version
Requires php Version ^7.4|^8.0
illuminate/support Version ^8.0
livewire/livewire Version ^2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package lao9s/livewire-modal-twitter contains the following files

Loading the files please wait ....