Releases: nene/prettier-plugin-sql-cst
Releases Β· nene/prettier-plugin-sql-cst
0.12.0
0.11.8
0.11.7
0.11.6
0.11.5
0.11.4
0.11.3
Support for latest BigQuery syntax
Upgraded the parser to support latest (as of 31. Jan 2024) BigQuery syntax.
Notably this includes:
- support for
PRIMARY KEY
andFOREIGN KEY
OPTIONS()
in view columnsGROUP BY
withCUBE()
,ROLLUP()
,GROUPING SETS
Improved PostgreSQL support
CREATE/DROP/ALTER INDEX
andREINDEX
are now supported
0.11.2
Improved PostgreSQL support
- Formatting of
CREATE TABLE
- Formatting of
CREATE FOREIGN TABLE
- Formatting of
ALTER TABLE
- Formatting of
CREATE/ALTER/DROP SEQUENCE
- Formatting of
CREATE/ALTER/DROP VIEW
- Formatting of
CREATE/ALTER/DROP MATERIALIZED VIEW
- Formatting of
REFRESH MATERIALIZED VIEW
- Formatting of
CREATE/ALTER/DROP SCHEMA
0.11.1
0.11.0
New features
- New option
sqlCanonicalSyntax
. When enabled (which is the default), the formatter will perform various transformations on the source code, like addingAS
keywords to table and column aliases, replacing some deprecated syntax with more modern one, etc.
Improved PostgreSQL and MySQL support
- Much improved formatting of CREATE TABLE and ALTER TABLE.
- Along with other parsing improvements form sql-parser-cst 0.23.0
Formatting improvements
- The formatting of various statements will now adapt to existing code. Similarly to how the formatting of SELECT statement already behaved - i.e. when the original code is on a single line, the formatter also tries to place it on a single line and will only break it up to multiple lines when the statement is short enough.
Bugfixes
- Created a script to automatically check for unused CST node fields, which uncovered several cases, where the formatter would end up silently deleting code. All fixed now and hopefully won't happen again.