Download the PHP package ctf0/blazar without Composer

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

This project is abandoned due to impracticality, i would highly recommend to try using ServiceWorkers and here is a little article to get you started.

Blazar

Latest Stable Version Total Downloads

Automate pre-rendering pages on the fly through utilizing puppeteer which runs in the background when needed without adding any overhead to the server nor to the user experience.


Installation

php artisan vendor:publish --provider="ctf0\Blazar\BlazarServiceProvider"


Config

config/blazar.php


Usage

Render Pages Automatically

Atm in order to pre-render any page, it have to be visited first but if you want to make sure that all is working from day one, you can use the excellent package laravel-link-checker by Spatie

Flushing The Cache

or from within your app

Bots Only

we now use CrawlerDetect instead of relying on '\?_escapedfragment'

if you decided to pre-render the pages for bots only, no need to the run the queue as the page will remain busy "stalled response" until rendered by puppeteer, which happens on the fly.

however because we are caching the result, so this will only happen once per page.

also note that we are saving the page cache equal to the url so even if you switched off the bots_only option, if the page is cached, we will always serve the cached result.


Notes

Queues

the worker should only fires when a url is visited & if this url is not cached, however if you have an unfinished old process, the queue will start processing pages on its own, so to fix that, simply restart the queue server beanstalkd, redis, etc...

Auth

as i dont know how to make laravel think that a page visited through puppeteer is the same as the current logged in user.

so trying to pre-render pages with auth middleware will be cached as if the user was redirected to the home page or whatever you've set to redirectTo under Constollers/Auth/LoginController.php & Middleware/RedirectIfAuthenticated.php

so to solve that, simply add dont-pre-render middleware to those routes and everything will work as expected. also make sure to add the same middleware to any route that needs fresh csrf-token for each user "login, register, etc.." to avoid getting CSRF Token Mismatch for other users trying to use those pages.

More Reading


All versions of blazar with dependencies

PHP Build Version
Package Version
Requires php Version ~7.0
illuminate/support Version ~5.4.0|~5.5.0|~5.6.0
jaybizzle/laravel-crawler-detect Version ^1.0
ctf0/package-changelog 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 ctf0/blazar contains the following files

Loading the files please wait ....