Skip to content

Implement formatter playground#950

Open
Zuruuh wants to merge 1 commit intocarthage-software:mainfrom
Zuruuh:formatter-playground
Open

Implement formatter playground#950
Zuruuh wants to merge 1 commit intocarthage-software:mainfrom
Zuruuh:formatter-playground

Conversation

@Zuruuh
Copy link
Contributor

@Zuruuh Zuruuh commented Jan 26, 2026

📌 What Does This PR Do?

Very simple implementation of a formatter playground. It doesn't support any configuration for now but definitely doable (would require server side changes though)

🔍 Context & Motivation

I'm working on integrating the formatter in my codebases and it would be easier to have a playground link to easily isolate, reproduce, and demonstrate the bugs I'd want to report.

🛠️ Summary of Changes

  • Add a new (sub)tabs system to the playground
  • Implement the formatter tab separately from the linter+analyzer one
  • Added lld to the nix flake, since it's required to build the mago wasm binary
image

📂 Affected Areas

  • Linter
  • Formatter
  • CLI
  • Composer Plugin
  • Dependencies
  • Documentation
  • Other (please specify):

📝 Notes for Reviewers

The code was mostly generated through AI to be honest since I have very few experience with vue, however I did re-read it, refactor, and tested it locally 👍

@Zuruuh Zuruuh force-pushed the formatter-playground branch from 0cfb321 to d6b7535 Compare January 27, 2026 09:10
@Zuruuh Zuruuh changed the title WIP Implement formatter playground Implement formatter playground Jan 27, 2026
@azjezz azjezz added c-formatter PHP code reformatting and style rules t-docs Documentation improvements labels Feb 2, 2026
@azjezz
Copy link
Member

azjezz commented Feb 18, 2026

Hi! sorry for late reply.

I'm not really understanding what this does 🤔

the current playground already has Format button to do this, am i missing something?

@Zuruuh
Copy link
Contributor Author

Zuruuh commented Feb 18, 2026

Hello, the point isn't really to just format the code but to make it easier to compare the code before and after it has been formatted. I think it makes it easier to find and report bugs for the formatter, and I took inspiration from the Biome toolchain, which already has it's own playground with a formatted output tab https://biomejs.dev/playground/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

c-formatter PHP code reformatting and style rules t-docs Documentation improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants