Releases: ajthinking/archetype
v1.0.0
Welcome to v1.0.0 💚
AstQueryBuilder
- Adds ability to enter Node class and properties in one go:
$astQuery->classMethod('name->name')
- Adds HigherOrderWhere which is a short syntax for where callbacks:
$this->file->astQuery()
->class()
->property()
->where->propertyProperty('name->name')->is($key)->get()
->replace(function() {
...
};
- Auto resolving where clauses allows for leaving a where clause without
get()
. Results are evaluated to see if they have results (considered thruty) or empty (falsy). - Adds
Dumpable
proxies on astQueryBuilder for ->dd->something() and ->dump->another - Adds missing PhpParser types in class map
- Remove option to use _-postfixed node types in class map
- Adds an opt-in visualizer/debug tool, see: #45
- Numerous bugfixes
Endpoints
- Improved ClassConst
Misc
fromString
can allow pseudo php
PHPFile::addMissingTags()->fromString('$hey = 1337')
- Allow reading files outside of the input root using an absolute path
- Add Tappable and Dumpable traits
Discontinued features ⚠️ 💀
In order to tighten this package up and consolidate around primary features, we will drop the following incomplete/broken functionality:
- Schema
- Project
- Generators
- Trait endpoint (planned to be revived in a better form)
Furthermore,
- Remove aliases for PHPFile and LaravelFile to enforce explicit facade usage
- Remove doctrine/dbal dependency
Internal changes
- All tests are moved to pest 🚀
- Introduce
TestablePHPFile
facade. - Introduce
TestableAstQueryBuilder
facade.
Missing and broken
- The docs are still not near as good as they should be.
- Some formatting bugs persist. It is most likely related to format preserving pretty printing. See incomplete test
v1.0.0 Prerelease
Whats new?
- Adds
remove()
ability for class constants.
Discontinued features
In order to tighten this package up and consolidate around primary features, we will drop the following:
- Schema
- Project
- Generators
Most of these feature were incomplete or otherwise broken. A side effect of this is we will no longer be depending on doctrine/dbal.
Tests
All tests are moved to pest and many uses an internal TestablePHPFile facade.
v0.2.8
Better array formatting 🎉 🎉 🎉
Works for newly created, loaded or modified code.
class Finally
{
protected $empty = [];
protected $one = [
'one',
];
protected $moreThanOne = [
'one',
'two',
];
}
Thanks for spotting this @jackmcdade
Bump dependencies
Fixes an issue with doctrine/dbal
NotInOperator bugfix and fresh dependencies.
🐛 Fix bug in notInOperator
by @ordago
🔒 Allow doctrine/dbal ^2.10
by @WorldSeso7
✅ Bump dependecies, typos and test updates
Dependency bugfix
Include nikic/php-parser as a dependency, don't assume it is included elsewhere.
Refactor and bugfixes
Merge pull request #19 from nathane/add-stubs-directory Add default stubs directory
Autoload Bugfix
Rename mismatching class name/file name. Fixes #15
Support class constant get/set
Laravel 8 Support
v0.2.1 🚀
- Tests on Laravel 8
- Format preserving code manipulation
- Ignores abstract models