Showing 10 of 2,133 results.

parse | The Document Parser

Parses the input document and returns an array of nodes. Argument Description $document The input document. 1 <?php 2 3 public function parse ( 4 string $ document 5 ) : array ;

Blade Documents

The Documents API is the simplest way to begin parsing and analyzing individual Blade templates and provides a cohesive API that combines many of the library's unique features. Documents are constructed from the nodes created by the document...

getNodeArray | Blade Documents

Gets the document nodes as a normal array. Returns a PHP array containing the nodes that represent the parsed template. The nodes returned by this call are the same as those from the getNodes method call. 1 <?php 2 3 public function getNodeArray (...

Core Validators | The Validate Command

The Blade Parser library provides many validation rules out of the box. You can learn more about each of them in the following sections.

Directive Spacing | The Validate Command

Class : DirectiveSpacingValidator The directive spacing validator emits a validation error when a directive does not have sufficient leading or trailing whitespace. The following template: 1 < span class = " @if @endif " > </ span > produces the...

Debug Directives | The Validate Command

Class : DebugDirectiveValidator The debug directives validator emits a validation error if any debug directives appear within a template. The following template: 1 @dd ( $ args ) would produce the following validation message: 1 Debug directive...