Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

ts-playground-plugin-prettier

xavdid96MIT0.0.6

A simple button to make valid playground code Prettier!

playground-plugin

readme

TypeScript Playground Plugin

A simple Typescript Playground Plugin to invoke Prettier

It's currently intentionally very simple, but may support more options later.

Running this plugin

As of 2020-11-27, it's available in the sidebar under plugins:

If it's not, you can also:

  • Open up the TypeScript Playground
  • Go the "Plugins" in the sidebar
  • Look for "Plugins from npm"
  • Add ts-playground-plugin-prettier
  • Reload the browser

Then it will show up as a tab in the sidebar.

Contributing

See CONTRIBUTING.md for the full details, however, TLDR:

git clone ...
yarn install
yarn start

Then tick the box for starting plugin development inside the TypeScript Playground.

changelog

Changelog

0.0.6

Released 2023-08-28

  • Fix a bug where the last line of text was duplicated (#5)

0.0.5

Released 2023-08-26

  • Install prettier as the default formatter, so you can use Alt + Shift + F to format (and undo works correctly) (#4)

0.0.4

Released 2023-06-06

  • Update prettier to 2.8.8, bringing support for const type parameters (#3)

0.0.3

Released 2023-02-28

  • Update prettier to take advantage of new TS features, like satisfies (#2)

0.0.2

Released 2021-01-24

  • Add undo button and support for custom prettier configs (#1)

0.0.1

Released 2020-10-09

  • Initial public release