Skip to content

Support library-specific plugin #4424

@ikatyang

Description

@ikatyang

from #4423 (review):

I think that we should start to figure out a way to do those kind of library-specific kind of transforms into plugins.

There are a lot of downsides with the current approach of bundling it inside of prettier:

  • Now we need to maintain all those ourselves
  • If jest changes their format, then you need to wait a new prettier release to be able to use it. This dramatically slow down iteration speed
  • Ideally jest would be in control of how their format their templates
  • We have a good relationship with jest but what if some library coming from someone else wanted to format their thing, we now have to figure out what specific library printing is worth being inside of prettier.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:apiIssues with Prettier's Application Programming Interfacearea:multiparserIssues with printing one language inside another, like CSS-in-JSarea:plugin apistatus:needs discussionIssues needing discussion and a decision to be made before action can be taken

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions