Skip to content

Releases: efabrica-team/phpstan-latte

0.17.0

27 Mar 12:20
Compare
Choose a tag to compare

Fixed

  • Updated coding standard (Possible BC break - added final or abstract to (almost) all classes)
  • Bleeding edge changes - updated typehints
  • Functions handling with FunctionExecutor in new Latte
  • Removed unformatPresenterClass of new PresenterFactory

0.16.3

26 Nov 22:55
e4945f1
Compare
Choose a tag to compare

Added

  • Support for PHP 8.3

0.16.2

22 Nov 13:18
Compare
Choose a tag to compare

Fixed

  • Fixed first class callable filters

0.16.1

11 Oct 21:29
Compare
Choose a tag to compare

Fixed

  • Standalone presenter action template is not analysed if presenter dir and template dir are siblings
  • Method call __toString() is considered template render call
  • Compatibility with nette/application 3.1.14 (SnippetDriver renanamed to SnippetRuntime)

0.16.0

24 Aug 19:52
Compare
Choose a tag to compare

Changed

  • All compiled templates from one run will be stored in one directory within tmpDir

Added

  • Feature: Separate phpstan command to analyse compiled templates (Turn this feature with parameter latte.features.phpstanCommand: "vendor/bin/phpstan {dir}")
  • Feature: Testing layout files for each presenter's action (Turn this feature with parameter latte.features.analyseLayoutFiles: true)

Fixed

  • Stubs for Latte\Essential\Filters
  • Fixed include recursion failsafe that wrongly prevented expected analysis of templates in different contexts

0.15.0

31 Jul 15:51
Compare
Choose a tag to compare

Added

  • Support for form groups
  • Collecting options for checkbox list and radio list and report if some non-existing option is used
  • Tip for error message "Latte template xxx.latte was not analysed"
  • Tip for standalone templates
  • Feature: Transform dynamic form controls to "dynamic" string (control with name $record->id will be transformed to "$record->id") (Turn this feature with parameter latte.features.transformDynamicFormControlNamesToString: true)
  • Support for object shape variables
  • latte extension to fileExtensions parameter to report unmatched errors also in latte (If it's causing any problems in your applications, please report issue and we will remove it)

Fixed

  • If condition is always true for CheckboxList::getLabelPart(), CheckboxList::getControlPart(), RadioList::getLabelPart() and RadioList::getControlPart()

0.14.0

26 Jul 19:07
Compare
Choose a tag to compare

Changed

  • Types handling - used smart extract feature from PHPStan (Possible problems please report any issue connected with variable types)
  • Not defined variables are marked with error Undefined variable ... (BC break - if error was ignored, you need to change ignored error pattern)

Added

  • Type int as param for Runtime::item() method to support integer names of Form containers
  • Transformer for ternary condition with is_object and dynamic form fields - it removes always true / always false condition errors
  • Errors Cannot call method endTag() on Nette\Utils\Html|string. and Cannot call method startTag() on Nette\Utils\Html|string. added to ignore list until they are fixed in nette/forms
  • Support for dynamic forms with known name
  • Allowed Stringable as link destination parameter value if strict mode is not enabled

Removed

  • ignore-next-line for dynamic inputs - should be solved by removing ternary condition for dynamic inputs (If you have any issue with this, please report it)

Fixed

  • Collecting of conditionally defined (optioinal) variables from array
  • "Cannot resolve latte template for action" when setView is used with bleeding edge
  • Form classes can now have custom params in constructor

0.13.2

10 Jul 07:52
Compare
Choose a tag to compare

Fixed

  • Avoid always terminating calls in links
  • Transformed html attributes

0.13.1

12 Jun 10:38
Compare
Choose a tag to compare

Fixed

  • Removed empty string as 1st argument from method calls getControlPart() and getLabelPart()
  • Added missing stub for BaseControl
  • Moved check for IntegerRange type to resolveStringsOrInts

0.13.0

05 Jun 10:30
Compare
Choose a tag to compare

Changed

  • Separated collection of Form Containers
  • Renamed CollectedFormField to CollectedFormControl (BC break)
  • Renamed FormFieldCollector to FormControlCollector (BC break)
  • Renamed FormFieldFinder to FormControlFinder (BC break)
  • Error message Form field with name "xxx" probably does not exist. has been changed to Form control with name "xxx" probably does not exist. (BC break)

Added

  • Support for numeric form container names

Fixed

  • Subcomponents in multi registered components
  • Stubs for Nette\Bridges\FormsLatte\Runtime::item
  • FilterString type contains also null because Nette cast all inputs to string first and null is also available
  • Ignored incorrect calls from latte Checkbox::getControlPart('') and Checkbox::getLabelPart('')