notion-commotion/attribute-validator

Finds attributes which do not have classes assigned.

1.01 2022-01-19 16:11 UTC

This package is auto-updated.

Last update: 2024-04-06 17:58:38 UTC


README

Used to find PHP 8 attributes without defined classes. While annotations will result in error if the class does not exist, not true for attributes. LICENSE

Installation

composer require notion-commotion/attribute-validator

Usage

<?php
use NotionCommotion\AttributeValidator\AttributeValidator;
$path = 'src';              // All files in directory
//or
$path = 'src/somefile.php'; // A single file 
$attributeValidator = AttributeValidator::create($path);
$attributeValidator->validate();