Download the PHP package jakewhiteley/bladezero without Composer

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

BladeZero

Import Laravel's Blade templating engine into non-Laravel applications the right way.

The wrong way

All other standalone versions of blade require ~16 dependencies, and run the Iluminate/Container and Illuminate/View packages in your app. This adds a ton of complexity to your app, and is considered a bad idea.

There are a few instances of packages rewriting the entire Blade engine from scratch, which creates the following typical issues:

The *right* way

BladeZero is a direct split from laravel/framework and only includes files directly needed to compile Blade templates - no Container, no View, no fuss.

95% of the code is a perfect match for the code written by Taylor Otwell and the Laravel contributors, meaning every single Blade feature is supported exactly as it should be.

Installation

Use Composer:

Usage

After pulling the package down, you need to provide the full paths to your templates and cache directories:

Extending BladeZero

As the BladeZero\Factory class is just a modifed Illuminate\View\Factory, all the methods you would expect are available:

BladeZero supports all the Blade features you know such as custom directives, custom if statements, components.

BladeZero lets you write your own View classes as this package is to provide the Blade rendering engine for your own projects - not include half of Laravel. In order to facilitate this, some functionality you would access vie the View facade is also available; such as making data available to all views, and view namespaces

Differences

Even though the Blade compiler is 100% the same as it's Laravel twin, your application is not.

Because of this, BladeZero provides methods to easily get the Laravel-specific features of Blade working in your framework:

@csrf

Use the setCsrfHandler method to specify how to provide the @csrf() directive with the correct token:

@auth

Set how your application handles auth directives such as @auth, @elseauth, and @guest:

@can

Set how your application handles permissions directives such as @can, @cannot, and @canany:

@inject

If your application uses a dependency injection Container, sepcify how services should be resolved via @inject:

@error

Allwos you to provide how the @error directive should work.

Your callback should return the first error string or false:


All versions of bladezero with dependencies

PHP Build Version
Package Version
Requires php Version ^7.4|^8.0
illuminate/collections Version v9.52.16
league/commonmark Version ^1.3|^2.0.2
symfony/finder Version ^5.4
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 jakewhiteley/bladezero contains the following files

Loading the files please wait ....