Commit graph

31 commits

Author SHA1 Message Date
Kathy Walrath 0f109da0d1 Updating the package:js README
Closes #37883
https://github.com/dart-lang/sdk/pull/37883

GitOrigin-RevId: e14be88991f39db80422e98399fab26c8e9c038e
Change-Id: Ic4e45420dcf6fe71b5c215c435cd72ffb6e665f4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113265
Reviewed-by: Nate Bosch <nbosch@google.com>
Commit-Queue: Kathy Walrath <kathyw@google.com>
2019-08-19 17:52:57 +00:00
Nate Bosch 60e474bf7a Add section on known bugs
For now stage this in the package:js README - that might not be the best
place for it long term since the details may change...

- Add a note that makes it explicit we expect all interop to use
  `package:js` instead of `dart:js`.
- Add notes about known limitations and differences between dart2js and
  DDC.

Change-Id: Ib4c967ea1435dd85f41f56646140352b125cee4c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/107560
Reviewed-by: Nicholas Shahan <nshahan@google.com>
Commit-Queue: Nicholas Shahan <nshahan@google.com>
2019-06-27 23:38:43 +00:00
Nate Bosch ec160b74dc Start cleaning up docs in package:js
- Remove some unnecessary details in the README. The SDK constraint
  duplicates the pubspec, the dependencies section duplicates automatic
  info on the pub site, and the contributing section duplicates generate
  Dart/SDK contributing information. The issue link is still useful
  since it fills in a template, but we should update it to include a
  label by default.
- Use "JavaScript" consistently in docs.
- Rephrase some doc comments for clarity.
- Drop `new` from examples.
- Use consistent single quotes in examples.
- Always show the `@JS()` annotation on `library` in examples.
- Move the note about factory constructors for anonymous classes to the
  annotation from the README.
- Bump the mimimum SDK to`2.0.0` since there isn't utility in claiming
  support for older SDKs.

There are stale docs remaining in the `varargs.dart` library that should
be handled separately by deleting that library.

Change-Id: Ida51d2ec3fd31210b55dc91042a0ac1cf77210b8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/107450
Commit-Queue: Nate Bosch <nbosch@google.com>
Reviewed-by: Nicholas Shahan <nshahan@google.com>
2019-06-27 21:36:54 +00:00
Jenny Messerly c6556dc1a3 [package:js] draft proposal to improve JS interop, see #35084
Change-Id: I77a01469113cdfe6c9c3533cfb398ab97d5cd3b0
Reviewed-on: https://dart-review.googlesource.com/c/89404
Reviewed-by: Vijay Menon <vsm@google.com>
Commit-Queue: Jenny Messerly <jmesserly@google.com>
2019-02-05 01:44:32 +00:00
Kevin Moore fa629d83d8 pkg/js: fix pubspec author
Change-Id: I4ef5d232c5ca6e80f9df0f8a329d83a13aaa3be5
Reviewed-on: https://dart-review.googlesource.com/65603
Reviewed-by: Kevin Moore <kevmoo@google.com>
2018-07-18 21:36:10 +00:00
Kevin Moore af613c7479 pkg/js: support Dart <3.0.0
Change-Id: Ifc625e6dd33e48e7f446b7d7f19b7c14febd0e52
Reviewed-on: https://dart-review.googlesource.com/65600
Reviewed-by: Phil Quitslund <pquitslund@google.com>
2018-07-18 21:30:42 +00:00
Kevin Moore 6b91739cec Making license files consistent across all packages
Helps with internal license concatenation

Change-Id: I3042ba2ec0ef5fcd35937254827560f8a97c2f8a
Reviewed-on: https://dart-review.googlesource.com/9363
Reviewed-by: Kevin Moore <kevmoo@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
2017-09-28 19:33:08 +00:00
Jacob Richman 4b0afdf5cb Run dartfmt on package:js
BUG=
R=alanknight@google.com

Review-Url: https://codereview.chromium.org/2750123003 .
2017-03-21 18:10:03 -07:00
Alexandre Ardhuin 3f1720069a Add a note on the README of js package (#27701) 2016-11-23 16:36:54 +01:00
Danny Tuppeny 984f5c928d Added js import to sample code. (#26985)
This import seems to be required for the sample code to pass the analyzer.
2016-08-22 09:20:06 -07:00
Jacob Richman bacd980554 Fix sdk version constraint for pkg:js 0.6.1
BUG=
R=kevmoo@google.com

Review URL: https://codereview.chromium.org/2175423004 .
2016-07-25 14:49:13 -07:00
Jacob Richman 410cde6023 Fix analyzer warnings in js_util_test, skip js_util_test in csp mode and baseline expectations for analyze_library.status
Update pkg/js CHANGELOG.md to address comment from previous CL.

BUG=

Review URL: https://codereview.chromium.org/2179153002 .
2016-07-25 13:20:25 -07:00
Jacob Richman 96ca5db7e5 Add JSNative utility class with static methods methods to efficiently manipulate typed JSInterop objects in cases where the member name is not known statically. These methods would be extension methods on JSObject if Dart supported extension methods. Update package js to export these methods. Implement in Dart2JS. Implement JS$ in dart2js.
BUG=
R=alanknight@google.com, sra@google.com

Review URL: https://codereview.chromium.org/2150313003 .
2016-07-25 09:59:01 -07:00
Nathan Kerr 83d8f91397 Remove duplicate word 2015-11-19 14:06:01 -08:00
Kevin Moore 3d43d6d51c pkg/js: prepare for 0.6.0 release
R=sigmund@google.com

Review URL: https://codereview.chromium.org/1456223002 .
2015-11-18 15:34:54 -08:00
Kevin Moore 87fc010974 pkg/js: moved example code to https://github.com/google/chartjs.dart/
R=jacobr@google.com

Review URL: https://codereview.chromium.org/1449053004 .
2015-11-17 11:11:07 -08:00
Kevin Moore e7e012e386 fix readme for pkg/js and prepare another release
Update SDK changelog to mention improved JS interop

R=jacobr@google.com

Review URL: https://codereview.chromium.org/1438003002 .
2015-11-11 12:19:43 -08:00
Kevin Moore 928e30586e update pkg/js for changes is 1.13-dev.7.7
R=jacobr@google.com

Review URL: https://codereview.chromium.org/1421513006 .
2015-11-04 14:39:24 -08:00
Alexandre Ardhuin 447b287d04 Update chart.js with @anonymous 2015-11-02 22:44:14 +01:00
Jacob Richman e0d2263bb3 Add @anonymous annotation and restrict object literal constructors to only anonymous classes. This frees up defining factory constructors that do not correspond to object literals on JS interop classes.
BUG=
R=sra@google.com

Review URL: https://codereview.chromium.org/1409033005 .
2015-10-29 19:18:19 -07:00
Jacob Richman eab2ef5d82 Rev pkg js version
BUG=
R=ochafik@google.com

Review URL: https://codereview.chromium.org/1425823003 .
2015-10-29 10:33:16 -07:00
Olivier Chafik 90f9686c01 Move varargs.dart to lib/src (not ready for external publicity yet). 2015-10-23 16:00:14 +01:00
Olivier Chafik f25a970187 Declarations for rest params / spread operator support in DDC (issue #24623). 2015-10-22 20:25:55 +01:00
Kevin Moore b74ce18b0c pkg/js: update version, example, and SDK constraint for annotation change
R=jacobr@google.com

Review URL: https://codereview.chromium.org/1417963002 .
2015-10-21 09:58:30 -07:00
Jacob Richman be1fcb9441 Switch Js to JS
BUG=
R=sigmund@google.com

Review URL: https://codereview.chromium.org/1410403003 .
2015-10-19 17:32:10 -07:00
Kevin Moore e32d7d7029 pkg/js: add link to example
Review URL: https://codereview.chromium.org/1406093002 .
2015-10-15 16:33:05 -07:00
Kevin Moore 045325b32e pkg/js: improved readme, added example
R=jacobr@google.com

Review URL: https://codereview.chromium.org/1411503002 .
2015-10-15 14:51:35 -07:00
Kevin Moore 9e8c868c3b Big cleanup to README. Added CHANGELOG.
R=jacobr@google.com

Review URL: https://codereview.chromium.org/1404873004 .
2015-10-15 10:46:58 -07:00
Jacob Richman 6dd851e2a4 Update version number in pkg/js pubspec in preparation for publishing the package.
BUG=
R=kevmoo@google.com

Review URL: https://codereview.chromium.org/1405653002 .
2015-10-15 09:40:50 -07:00
Jacob Richman ff3309993c Fix version constraint so that package:js is fine to use with prerelease versions of the SDK
BUG=
R=nweiz@google.com

Review URL: https://codereview.chromium.org/1398973006 .
2015-10-13 14:32:15 -07:00
Jacob Richman cd2752431e Support user generated custom native JS classes.
BUG=
R=jmesserly@google.com, sra@google.com

Review URL: https://codereview.chromium.org//1318043005 .
2015-10-13 13:15:28 -07:00