plugin-php
plugin-php copied to clipboard
Prettier PHP Plugin
**Prettier 2.0.0** **PHP Plugin 0.18.4** ```json "prettier": { "phpVersion": "8.0", "useTabs": true, "singleQuote": true } ``` **Input:** ```php $measurement = (fn($m): Measurement => $m)(Measurement::query()->find($id, ['time', 'raw_gyro'])); ```  **Output:** ```php...
**Prettier ^2.6.1** **PHP Plugin ^0.18.4** ```sh # Options (if any): --single-quote ``` **Input:** ```javaScript var codeStr = `
**Prettier 2.6.2** **PHP Plugin 0.18.5** **Input:** ```php class Test { protected $array1 = [ 'published', 'title', 'description', 'position', 'nid']; protected $array2 = [ 0=>'published', 'title', 'description', 'position', 'nid']; } ```...
**@prettier/plugin-php v0.16.3** [Playground link](https://loilo.github.io/prettier-php-playground/#N4IgDgTgpgLjCWUIHkwIPYDsDOIBcok8mMA6vACYwAW+AHAAwA0IMAhgEblW14AsLAK7YoAFU648AMzYAbES2zEA5rKgBFQehhR8M+VBZhqYAGpIlWfCACsAOj4gWMCG3iyVAYXQBbH2wAFAAkA-BdBQxAOVwBjKABlGABPNWswbAgAWgAmJxBoAEdBeGgA12V-PTkFEGIRCBgytgq2KoMAXxYoCngYdBQ0eCxJUDZsGDaRTtrMMEEJvBAAHgB+YzAAHUx4KQACAAoAEil0dABKXeAtjZgAelvdgFEADzYfMDVdmN8fKBJrmArAB8AJuSx6ADcgUtbpCQZgwWsTFt2rtgSB2kA) **Input:** ```php ``` **Output:** ```php ```
Hello, I am using Visual Studio Code for editing .php files. How can I set up Prettier plugin to format php in vs code. I tried to follow README.md but,...
Hello, Same issue like #1798, but instead of consts, it breaks protected/public/private definition. Thanks, **@prettier/plugin-php v0.18.3** [Playground link](https://loilo.github.io/prettier-php-playground/#N4IgDgTgpgLjCWUIHkwIPYDsDOIBcok8mMA6vACYwAW+AHAAwA0IMAhgEblW14AsLAK7YoAFU648AMzYAbES2zEA5rKgBFQehhR8M+VBZhqYAGpIlWfCACsAOj4gWMCG3iyVAYXQBbH2wAFAAkA-BdBQxAOVwBjKABlGABPNWswbAgAWgAmJxBoAEdBeGgA12V-PTkFEGIRCBgytgq2KoMAXxYoCngYdBQ0eCxJUDZsGDaRTtrMMEEJvBAAHgB+YzAAHUwtmNkx7AACTz3sbABBA+AtjZhIbSgYnQoDgBIdcYOAXgOARgBuLYHA7XGAAelBB0gsAQSEy8GUmH6UEBwNuEHuj26r3eMC+B2yAMw7RA7SAA) **Input:** ```php
**@prettier/plugin-php v0.18.4** [Playground link](https://loilo.github.io/prettier-php-playground/#N4IgDgTgpgLjCWUIHkwIPYDsDOIBcok8mMA6vACYwAW+AHAAwA0IMAhgEblW14AsLAK7YoAFU648AMzYAbES2zEA5rKgBFQehhR8M+VBZhqYAGpIlWfCACsAOj4gWMCG3iyVAYXQBbH2wAFAAkA-BdBQxAOVwBjKABlGABPNWswbAgAWgAmJxBoAEdBeGgA12V-PTkFEGIRCBgytgq2KoMAXxYoCngYdBQ0eCxJUDZsGDaRTtrMMEEJvBAAHgB+YzAAHUwtmNkx7AACADF0dAPgLY2YOY4PGIOpQUwYjEwDgH13mOHwl4AKaBsChYWRJA5EABubB0B3GEBUBwAJBw2AAvACUwHaW3aIHaQA) **Input:** ```php
Would it be practical to add an option to automatically ignore files that contain inline HTML? I usually do this via .prettierignore so I can use prettier on non-templating files,...
Bumps [strip-ansi](https://github.com/chalk/strip-ansi) from 6.0.0 to 7.0.1. Release notes Sourced from strip-ansi's releases. v7.0.1 Upgrade dependencies ed41f38 https://github.com/chalk/strip-ansi/compare/v7.0.0...v7.0.1 v7.0.0 Breaking Require Node.js 12 7cda68d This package is now pure ESM. Please...
My setup looks like this: VS Code (latest version - no updates available) Prettier code formatter (6.4.0) - Installed via VS Code extensions Prettier/plugin-php - installed globally using: ` npm...