From b8ccc2082c8f96db839bba5550ae5cc4d47e381e Mon Sep 17 00:00:00 2001 From: Kamil Kras <38427679+xVemu@users.noreply.github.com> Date: Wed, 15 Jan 2025 10:23:50 +0100 Subject: [PATCH] Update dart_style to 3.0.0 --- CHANGELOG.md | 4 ++++ lib/src/utils/utils.dart | 2 +- pubspec.yaml | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d49df32..e32c61a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,10 @@ All notable changes to the "flutter-intl" extension will be documented in this f The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## 2.8.9 - Unreleased + +- Update `dart_style` dependency to support `v3.x.x` + ## 2.8.8 - 2025-01-08 - Update `intl` dependency diff --git a/lib/src/utils/utils.dart b/lib/src/utils/utils.dart index 0419be8..543e2fe 100644 --- a/lib/src/utils/utils.dart +++ b/lib/src/utils/utils.dart @@ -45,7 +45,7 @@ String formatJsonMessage(String jsonMessage) { /// Formats Dart file content. String formatDartContent(String content, String fileName) { try { - var formatter = DartFormatter(); + var formatter = DartFormatter(languageVersion: DartFormatter.latestLanguageVersion); return formatter.format(content); } catch (e) { info('Failed to format \'$fileName\' file.'); diff --git a/pubspec.yaml b/pubspec.yaml index 7aecc68..e0382bd 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -10,7 +10,7 @@ dependencies: analyzer: ^6.0.0 archive: ">=3.0.0 <5.0.0" args: ^2.0.0 - dart_style: ^2.0.0 + dart_style: ^3.0.0 http: ">=0.13.0 <2.0.0" intl: ">=0.17.0 <0.21.0" path: ^1.8.0