crodas/notoj
Notoj is a lightweight PHP annotation parser that reads docblock annotations with a fast tokenizer, no heavy dependencies. Define annotation classes extending Notoj's base, then parse methods, classes, and properties to build routing, validation, or metadata layers.
Consider it when:
doctrine/annotations, symfony/* components, or native PHP 8 attributes is a contained change.Look elsewhere when:
To leadership: This is a small, single-purpose utility that lets us ship declarative, metadata-driven configuration without building a parser ourselves. It is commodity infrastructure, not a strategic bet — cheap to adopt, cheap to remove, and it should stay invisible to customers. Because it is a low-visibility third-party dependency, we will confine it behind an internal interface and budget a migration to native PHP 8 attributes as the long-term direction.
To engineering: Adopt it only if we need DocBlock metadata parsing now and want to avoid a bespoke parser. Wrap it immediately — no direct calls from product code — pin the version, and add a test suite that pins the annotation grammar we rely on. Treat PHP 8 attributes as the target state and this package as a transitional bridge; do not let new annotation usage spread beyond the agreed grammar. If the dependency proves unmaintained or the grammar outgrows it, the wrapper makes replacement a contained, low-risk change.
Bottom line: worth it for internal tooling and transitional framework work; not worth it as a long-term platform commitment.
How can I help you explore Laravel packages today?