Markdownify icon indicating copy to clipboard operation
Markdownify copied to clipboard

Fix PHP8.3 support

Open tzi opened this issue 1 year ago • 3 comments

tzi avatar Feb 23 '24 16:02 tzi

Please merge the php8.3 fix to the master

achanizbekovidnow avatar Aug 28 '24 10:08 achanizbekovidnow

HI @tzi!

While working on your PHP 8.3 maintenance branch, would you mind also looking at the PHP 8.3 deprecation notices in the current release? I get these notices with 2.3.1 under PHP 8.3.

 [PHP Decprecated] Creation of dynamic property Markdownify\ConverterExtra::$tableLookaheadHeader is deprecated in /vendor/pixel418/markdownify/src/ConverterExtra.php:87
 [PHP Decprecated] Creation of dynamic property Markdownify\ConverterExtra::$tdSubstitute is deprecated in /vendor/pixel418/markdownify/src/ConverterExtra.php:96
[PHP Decprecated] Creation of dynamic property Markdownify\ConverterExtra::$tableLookaheadBody is deprecated in /vendor/pixel418/markdownify/src/ConverterExtra.php:98

A quick look and it seems ConverterExtra potentially needs three variables declared:

private string $tableLookaheadHeader;
private string $tdSubstitute;
private string $tableLookaheadBody

I see this has been open for a while, so let me know if you need help to conclude it.

Cheers, Scott

sc0ttdav3y avatar Sep 21 '24 06:09 sc0ttdav3y

Update: I've created a fresh PR https://github.com/Elephant418/Markdownify/pull/49 that incorporates this PR and my additional PHP 8.3 deprecation fixes.

sc0ttdav3y avatar Sep 24 '24 07:09 sc0ttdav3y