Skip to content

Commit 143dc05

Browse files
kevmooCommit Queue
authored andcommitted
[pkg:js] Clarify and improve discontinue message
Add library-level docs duplicating the discontinue message Related to #59716 Change-Id: Ib414a56c4412db0d9701c3d11f75354295775f9b Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/408642 Commit-Queue: Srujan Gaddam <[email protected]> Reviewed-by: Srujan Gaddam <[email protected]> Auto-Submit: Kevin Moore <[email protected]>
1 parent 274f563 commit 143dc05

File tree

3 files changed

+18
-3
lines changed

3 files changed

+18
-3
lines changed

pkg/js/README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22
[![package publisher](https://img.shields.io/pub/publisher/js.svg)](https://pub.dev/packages/js/publisher)
33

44
> [!CAUTION]
5-
> This package is discontinued.
6-
> Prefer using `dart:js_interop` instead of this package for JS
7-
> interop. See the [JS interop documentation] for more details.
5+
> This package is discontinued. Prefer using
6+
> [`dart:js_interop`](https://api.dart.dev/dart-js_interop/dart-js_interop-library.html)
7+
> for JS interop. See the
8+
> [JS interop documentation](https://dart.dev/interop/js-interop) for more
9+
> details.
810
911
Use this package when you want to call JavaScript APIs from Dart code, or vice
1012
versa.

pkg/js/lib/js.dart

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
/// > [!CAUTION]
6+
/// > This package is discontinued. Prefer using
7+
/// > [`dart:js_interop`](https://api.dart.dev/dart-js_interop/dart-js_interop-library.html)
8+
/// > for JS interop. See the
9+
/// > [JS interop documentation](https://dart.dev/interop/js-interop) for more
10+
/// > details.
511
@Deprecated('Use dart:js_interop instead')
612
library;
713

pkg/js/lib/js_util.dart

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,13 @@
33
// BSD-style license that can be found in the LICENSE file.
44

55
/// Utilities for interoperating with JavaScript.
6+
///
7+
/// > [!CAUTION]
8+
/// > This package is discontinued. Prefer using
9+
/// > [`dart:js_interop`](https://api.dart.dev/dart-js_interop/dart-js_interop-library.html)
10+
/// > for JS interop. See the
11+
/// > [JS interop documentation](https://dart.dev/interop/js-interop) for more
12+
/// > details.
613
@Deprecated('Use dart:js_interop instead')
714
library;
815

0 commit comments

Comments
 (0)