Plugin-php: Include Options for Readme + Good Job Contributors

Created on 4 May 2018  路  4Comments  路  Source: prettier/plugin-php

Hi there.

First off, I'm super excited for this project to reach a stable milestone as so many hybrid web-apps (PHP + JS) can now use one formatter for everything. This plugin is getting a lot of recent attention in the community. Having clean integration with no more blocking issues ---- will be huge for prettier adoption in the PHP community. So thumbs up to all those making this project possible.

I was wondering if it's possible to include the available options on the Readme? I think this would be useful. Obviously, I'm aware of the issue with tons of options; however, there are still the core ones (e.g. trailingCommas, etc.) ... it would be nice to have those all documented for easy reference. A small section in Readme would suffice.

enhancement

Most helpful comment

Found this: https://github.com/prettier/plugin-php/pull/78
Looks like we support trailing commas already, i totally forgot about this :laughing:

All 4 comments

Hi @virgofx,
first of all: Thanks for your kind words - we definitely share your excitement about this project!
I agree that listing the options in the README would be a good idea, especially because only some of the official options should have an effect in our plugin:

  • print width
  • tab width
  • tabs
  • range
  • (parser)
  • filepath
  • require pragma
  • insert pragma
  • trailing commas (as mentioned below)

But we ignore:

  • semicolons
  • quotes
  • bracket spacing
  • jsx brackets
  • arrow function parens
  • prose wrap

I'm not sure if all of the options that _should_ work are actually working today. Maybe it would be best to test them, and add only the working ones to the README? @mgrip @evilebottnawi

I agree we should documentation all options what support from prettier :+1:

@czosel Most everything seems okay ... only question/concern is trailing commas. That is required by industry now in virtually every language to reduce diffs for multiline arrays, etc. Prettier-php will need to support this as default or as an option.

Found this: https://github.com/prettier/plugin-php/pull/78
Looks like we support trailing commas already, i totally forgot about this :laughing:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

alexander-akait picture alexander-akait  路  3Comments

alexander-akait picture alexander-akait  路  5Comments

czosel picture czosel  路  6Comments

czosel picture czosel  路  5Comments

loilo picture loilo  路  3Comments