Download the PHP package rainlab/livewire-plugin without Composer

On this page you can find all versions of the php package rainlab/livewire-plugin. 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-plugin

Livewire Plugin

Integrate Laravel Livewire components inside October CMS themes, app and plugins, with templates provided by Twig, Blade or PHP.

Requirements

Installation

To install with Composer, run this from your project root.

Rendering Livewire Components

Use the livewire CMS component to activate Livewire in your CMS theme page or layout. For example, your page may look like this.

Next, render a Livewire component using the {% livewire %} Twig tag.

You may pass variables to the component using an equal sign (=).

Note: For proper operation, your CMS layout should include the {% styles %} and {% scripts %} placeholder tags, as described in the placeholder documentation.

File Locations

By default, classes are stored in the app/Livewire directory. However, you can register custom classes within plugins (see below).

Views are stored in the in app/views/livewire directory by default. The following template syntaxes are supported in the views directory, determined by their file extension.

Extension Template Engine
.htm October Twig
.blade.php Laravel Blade
.php PHP Template

Plugin Registration

To register Livewire components in your plugins using the registerLivewireComponents override method. The method should return a class name as the key and the component alias as the value.

In the above example, the October\Demo\Livewire\Todo class refers to the following file locations:

The class should return its view path by overriding the render method, and returns a View instance relative to the plugin.

The component can be rendered anywhere using the demoTodo alias.

Usage in CMS Components

You may implement Livewire in your CMS components using the RainLab\Livewire\Behaviors\LivewireComponent behavior. This implementation will ensure that the necessary dependencies are registered when the component is used.

Then render the component using the {% livewire %} tag.

Alternatively, you can render the component in PHP using the renderLivewire method.

Usage in Backend Controllers

You may implement Livewire in your backend controllers using the RainLab\Livewire\Behaviors\LivewireController behavior. This implementation will ensure that the necessary dependencies are registered with the controller.

Then render the component using the makeLivewire method.

Usage Example

Here we will create a component in the app directory and render it on a CMS page freestanding. First, create a file called app/views/livewire/counter.htm with the following content.

Create a file called app/Livewire/Counter.php with the following contents.

This component now be rendered as counter in your CMS templates. The component name is derived from the class name.

For example, in the demo theme, create a template called test.htm with the following content. Then open the /test URL.

See Also

License

This plugin is an official extension of the October CMS platform and is free to use if you have a platform license. See EULA license for more details.


All versions of livewire-plugin with dependencies

PHP Build Version
Package Version
Requires livewire/livewire Version ^2.12|^3.0
composer/installers Version ~1.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 rainlab/livewire-plugin contains the following files

Loading the files please wait ....