A monorepo for Prettier Scala formatting tools
This monorepo contains:
| Package | Description | Version |
|---|---|---|
| @simochee/prettier-plugin-scala | Prettier plugin for formatting Scala code | |
| @simochee/scala-parser | Scala parser built with Chevrotain |
npm install --save-dev prettier @simochee/prettier-plugin-scalaThen format your Scala files:
npx prettier --write "**/*.scala"See the plugin documentation for detailed usage.
npm install @simochee/scala-parserimport { parse } from '@simochee/scala-parser';
const cst = parse('class Foo { def bar = 42 }');See the parser documentation for API details.
This project uses:
- pnpm for package management
- Turborepo for monorepo tooling
- Vitest for testing
- TypeScript for type safety
# Clone the repository
git clone https://github.com/simochee/prettier-plugin-scala
cd prettier-plugin-scala
# Install dependencies
pnpm install
# Build all packages
pnpm build
# Run tests
pnpm testprettier-plugin-scala/
├── packages/
│ ├── prettier-plugin-scala/ # Main Prettier plugin
│ └── scala-parser/ # Chevrotain-based parser
├── test-fixtures/ # Test samples and examples
├── docs/ # Documentation
└── turbo.json # Turborepo configuration
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Add tests for your changes
- Ensure all tests pass
- Submit a pull request
See CLAUDE.md for detailed development guidelines.
MIT © simochee