Commit Graph

9 Commits

Author SHA1 Message Date
blois@google.com 3d0ace5885 Re-try of Tightening up dart2js load timing.
This is a fixup of https://codereview.chromium.org/22488002/, first patch is the original, subsequent the fixes.

BUG=
R=ahe@google.com, vsm@google.com

Review URL: https://codereview.chromium.org//23121004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26244 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-15 23:57:07 +00:00
ricow@google.com 653c15bf55 Revert revision 26149.
This is causing IE bots to fail

R=ahe@google.com, kustermann@google.com

Review URL: https://codereview.chromium.org//23201005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26186 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-15 11:19:11 +00:00
blois@google.com daf090e7b3 Tightening up dart2js load timing.
The timing of main() execution in dart2js currently occurs after 'loaded' which is quite late in the page load phase (after all images) and is inconsistent with Dartium.

In order to get the timing more consistent with Dartium and more consistent in general this CL makes a couple of changes:
 - dart2js generated code is now executed synchronously- this gives end developers more control over timing of main().
 - A warning is generated if main() is executed during document parse time- this is primarily to ease the transition and let users know what needs to be done to more closely match Dartium behavior.
 - dart.js bootstrapper no longer waits for DOMContentLoaded- the modified script tags will be executed after parse phase, the additional delay should not be necessary.

Breaking changes:
 - dart2js main() execution in standard project templates now occurs after document parse but before all assets have been loaded
 - Script tags directly referencing dart.js files will now execute synchronously. It's recommended that defer tags be added to these, or that they be moved to the end of the body tag.
 - dart.js bootstrapper will now only auto-load script tags which occur before it on the page.

BUG=4718
R=sra@google.com, vsm@google.com

Review URL: https://codereview.chromium.org//22488002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26149 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-14 20:51:45 +00:00
vsm@google.com a81a6fcce6 RFC: introduce dart:js
This is a port of js-interop with an optimized dart2js compilation.
It also gets rid of noSuchMethod.
I also made some renamings inspired by https://github.com/dart-lang/js-interop/issues/68

BUG=
R=vsm@google.com

Review URL: https://codereview.chromium.org//15782009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25018 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-15 19:44:44 +00:00
vsm@google.com 609c1239d5 Move interop js code out of dart.js
BUG=7973

Note: this is a breaking change and would be advertised as such.
Anyone using js-interop would need to explicitly include:

<script type="text/javascript" "pkg/browser/lib/interop.js"></script>

along with dart.js in their HTML.  Those who don't need js-interop can
save on this code.

Alexandre: I'm imagining interop.js would be the landing spot for
dart:js bootstrap code as well.

R=alexandre.ardhuin@gmail.com, dgrove@google.com

Review URL: https://codereview.chromium.org//16592002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23855 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-11 15:33:18 +00:00
vsm@google.com f402bff98a Remove tabs from dart.js
My bad...

R=dgrove@google.com

Review URL: https://codereview.chromium.org//15042003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22474 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 18:44:45 +00:00
vsm@google.com 6800a0e5a9 Workaround for 8455
BUG=8455
R=ahe@google.com

Review URL: https://codereview.chromium.org//14790017

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22375 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-03 16:42:30 +00:00
vsm@google.com e2ef36a751 Fix dart.js to handle query strings
Still needs an automated test, but this passes my local ones.

BUG=http://code.google.com/p/dart/issues/detail?id=8408

Review URL: https://codereview.chromium.org//12212203

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18549 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-14 23:38:20 +00:00
vsm@google.com 8eacd88652 Create an sdk package to host dart.js
Devon: I think we'd need corresponding editor changes.  The editor could use either pub or just replace the path (as mentioned in the bug).

BUG=6723

Review URL: https://codereview.chromium.org//11774006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16812 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-08 18:35:22 +00:00