From ac09e08ac8a015529d8a8168becc8806972bfbec Mon Sep 17 00:00:00 2001 From: "jmesserly@google.com" Date: Tue, 18 Mar 2014 21:38:24 +0000 Subject: [PATCH] [browser] restore previous version with tighter SDK lower bound follow up to http://code.google.com/p/dart/source/detail?r=34062 R=sigmund@google.com Review URL: https://codereview.chromium.org//203973002 git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@34066 260f80e4-7a28-3924-810f-c04153c831b5 --- pkg/browser/README.md | 17 +++++++++++++++++ pkg/browser/lib/interop.js | 9 ++++----- pkg/browser/pubspec.yaml | 6 +++--- 3 files changed, 24 insertions(+), 8 deletions(-) diff --git a/pkg/browser/README.md b/pkg/browser/README.md index 32c736c0c6a..fa968513d98 100644 --- a/pkg/browser/README.md +++ b/pkg/browser/README.md @@ -1,3 +1,8 @@ +This package contains dart.js, and previously contained interop.js + +dart.js +======= + The dart.js file is used in Dart browser apps to check for native Dart support and either (a) bootstrap Dartium or (b) load compiled JS instead. Previously, we've recommended that you add a script tag pointing the version of dart.js in @@ -20,3 +25,15 @@ If you do not wish to use pub, you may host a copy of this file locally instead. In this case, you will need to update it yourself as necessary. We reserve the right to move the old file in the repository, so we no longer recommend linking to it directly. + +interop.js +========== + +This script was required for dart:js interop to work, but it is no longer +needed. The functionality is now supported by dart:js directly. + +If you previously had a script such as this, please remove it: + +```html + +``` diff --git a/pkg/browser/lib/interop.js b/pkg/browser/lib/interop.js index d7c7de60929..ec02e5857ad 100644 --- a/pkg/browser/lib/interop.js +++ b/pkg/browser/lib/interop.js @@ -2,9 +2,8 @@ // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. -// Type for remote proxies to Dart objects with dart2js. -// WARNING: do not call this constructor or rely on it being -// in the global namespace, as it may be removed. -function DartObject(o) { - this.o = o; +// TODO(jmesserly): remove this script after a deprecation period. +if (typeof console == "object" && typeof console.warn == "function") { + console.warn('