Download the PHP package junohamburg/kirby-reload-on-save without Composer

On this page you can find all versions of the php package junohamburg/kirby-reload-on-save. 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 kirby-reload-on-save

Kirby Reload On Save

This plugin for Kirby 3 and Kirby 4 automatically reloads the frontend when content changes are saved in the panel.

It uses the Broadcast Channel API to communicate between panel and frontend. There is no build tool or npm install necessary, so the plugin can be used both in your local development and your production environment.

https://github.com/junohamburg/kirby-reload-on-save/assets/77532479/769d44b9-cdd7-47f7-b1f0-b4c260393cfd

Clicking "Save" or using CMD+S / CTRL+S saves the content and reloads the frontend.

Installation

Download

Download and copy this repository to /site/plugins/kirby-reload-on-save.

Composer

Git submodule

Setup

Enable the plugin in your config using in the ready option shown below. That way, the plugin is only active when the user is logged in and it does not interfere with the Kirby cache.

site/config/config.php

Tip: If you only want to enable the plugin in your local development environment, use domain/environment specific config files: Kirby docs

How it works

The plugin uses the Broadcast Channel API to communicate between tabs: One Broadcast Channel is added in the panel, another one is added in the frontend using a page.render:after hook. When the user saves content changes in the panel, the Broadcast Channel in the panel sends a message to the frontend to reload the page.

Limitations

  1. This plugin will reload any open page in your frontend. There is no distinction which page (or file or user) was saved in the panel – only if the page belongs to the same site.
  2. Uploading files, adding new pages, changing the page title or other actions that do not trigger a content/save action in the panel will not reload the frontend automatically.
  3. The Broadcast Channel API is supported by any modern browser, except Safari 15.3 and older: Can I Use

License

MIT

Credits


All versions of kirby-reload-on-save with dependencies

PHP Build Version
Package Version
Requires getkirby/composer-installer Version ^1.1
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 junohamburg/kirby-reload-on-save contains the following files

Loading the files please wait ....