Releases: prettier-solidity/prettier-plugin-solidity
v2.0.0
This is a new major version of Prettier Plugin Solidity.
The changes from v1 are minimal, but there are a couple of breaking changes.
The plugin now uses Slang as the parser by default. Slang is a more powerful and correct parser that improves formatting in many edge cases—especially when comments are involved.
If you had the parser explicitly set in your .prettierrc
(e.g., "parser": "solidity-parse"), you'll need to update it to:
"parser": "slang"
If you don't have the parser option set in your config, no action is needed.
The old ANTLR-based parser is still supported in v2, but it's deprecated and will be removed in the next major version.
v1.4.3
v2.0.0-beta.8
What's Changed
- Adding support for Slang
1.0.0
by @Janther in #1106 - Reintroducing tests for
antlr
by @Janther in #1107
Full Changelog: v2.0.0-beta.7...v2.0.0-beta.8
v2.0.0-beta.7
What's Changed
Full Changelog: 2.0.0-beta.6...v2.0.0-beta.7
2.0.0-beta.6
New features
Format changes
// Original
import * as SomeSymbol from "AnotherFile.sol";
// prettier-plugin-solidity@2.0.0-beta.5
// { parser: 'solidity-parse' }
import "AnotherFile.sol" as SomeSymbol;
// prettier-plugin-solidity@2.0.0-beta.6
// { parser: 'solidity-parse' }
import * as SomeSymbol from "AnotherFile.sol";
Breaking changes
Full Changelog: v1.4.1...v1.4.2
v1.4.2
New features
Format changes
// Original
import * as SomeSymbol from "AnotherFile.sol";
// prettier-plugin-solidity@v1.4.1
import "AnotherFile.sol" as SomeSymbol;
// prettier-plugin-solidity@v1.4.2
import * as SomeSymbol from "AnotherFile.sol";
Breaking changes
Full Changelog: v1.4.1...v1.4.2
v2.0.0-beta.5
Smaller bundled file size and performance improvements.
v2.0.0-beta.4
Fix a bug in the previous release with the unpkg
endpoint.
v2.0.0-beta.3
Features
- Support for Slang 18
- Support for the browser was added back
Breaking changes
- Slang provides a wasm endpoint that relies on ESM features. Therefore we had to drop UMD and CommonJS support in order to bundle a package for the browser.
v2.0.0-beta.2
Moving closer to a release candidate, this pre-release adds the following features:
- Support for
@nomicfoundation/slang@0.17.0
#1043 - Infer solidity version from source code #1047