Biome as it is now didn't work out for us 😢
Summary for posterity:
* it IS much, much faster, fast enough to skip any sort of caching
* we couldn't fully replace Prettier just yet. We use Prettier
programmatically to format code in docs, and Biome's JS interface is
officially alpha and [had legacy peer deps
set](https://github.com/biomejs/biome/pull/1756) (which would fail our
CI build as we don't allow installation warnings)
* ternary formatting differs from Prettier, leading to a large diff
https://github.com/biomejs/biome/issues/1661
* import sorting differs from Prettier's
`prettier-plugin-organize-imports`, making the diff even bigger
* the deal breaker is a multi-second delay on saving large files (for us
it's
[Editor.ts](https://github.com/tldraw/tldraw/blob/main/packages/editor/src/lib/editor/Editor.ts))
in VSCode when import sorting is enabled. There is a seemingly relevant
Biome issue where I posted a small summary of our findings:
https://github.com/biomejs/biome/issues/1569#issuecomment-1930411623
Further actions:
* reevaluate in a few months as Biome matures
### Change Type
- [x] `internal` — Any other changes that don't affect the published
package
Biome seems to be MUCH faster than Prettier. Unfortunately, it
introduces some formatting changes around the ternary operator, so we
have to update files in the repo. To make revert easier if we need it,
the change is split into two PRs. This PR has only config/package
changes and is expected to fail the CI.
## Change Type
- [x] `minor` — New feature
This reverts commit b6716a3750.
Not sure why, but this introduced a `/// <references />` comment in the
tldraw/tldraw api-report.md file that doesn't show up when you build
from brivate. Reverting for now.
### Change Type
- [x] `dependencies` — Changes to package dependencies[^1]
### Test Plan
-
### Release Notes
-
This PR improves the language selection.
Previously, we would miss the user's languages that included a locale.
For example, if a user's languages were `['en-US', 'fr'], then they
would get 'fr' because 'en-US' wasn't in our table—though 'en' was!
We were already doing the splitting elsewhere but now we do it here,
too.
### Release Note
- Improves default language
---------
Co-authored-by: Lu[ke] Wilson <l2wilson94@gmail.com>
* Update prettier to latest
* Add format command
* Create .prettierignore
* Add prettier plugin sort imports
* Update prettier config
* Update prettier config
* Update .prettierignore
* Fix @babel/parser conflict
https://github.com/trivago/prettier-plugin-sort-imports/issues/156
* Revert "Update .prettierignore"
This reverts commit 282e5b838376f16b3df7f4c1f99f1106baaffea4.
* Revert change for apps/www/pages/v/[id].tsx
* Sort imports
Moves the third party imports to the top, "~" imports in middle, and "./" at last
* Sorting of the specifiers
in an import declarations
* [www] use path vs "../"
* [core] use path "~" vs "../"
* [tldraw] use path "~" vs "../.../"
* [tldraw] use path "~" vs "../"
* [tldraw] Cleanup
* Update prettier config
* Last use path "~" vs "../.../"
* [www] Fix order of the third party imports
* Clean prettier config
* Changed Wardlt use back to Tldraw. Added some VS Code marketplace categories
* Missed removing one Wardlt mention
* Initial support for esbuild based vscode extension workflow.
* Hacky start of vs code extension build script
* Fixed categories of extension
* Added script for generating VS Code extension installer
* Temp fix for file format change affecting VS Code extension
* Temp fix for file format change issue
* Cleanup, prevent changes from saving pagestates
* Remove logic around saving pageState
* standardize capitalization
* v0.1.8
* Edit readme, scripts
* Update .eslintignore
* v0.1.9
* v0.1.10
* cleans up build scripts, adds publishing notes
* Added VS Code extension implementation references links. start:vscode now auto opens the extension folder in VS Code
* Removed step from VS Code README to manually open the extensions folder
* Removed file
* v0.1.11
* v0.1.12
* Fix empty file
* v0.1.13
* README cleanup
* v0.1.14
* Update TLDrawEditorProvider.ts
* v0.1.15
* Fix types for file extension (sort of) build script for extension
Co-authored-by: Steve Ruiz <steveruizok@gmail.com>