Archive for November 5th, 2007

Gmail’s core JavaScript gets a facelift

Gmail’s dev team has just recently rewritten most part of the core javascripts for Gmail and was released to the public right away.

http://gmailblog.blogspot.com/2007/10/code-changes-to-prepare-gmail-for.html

So recently the Gmail team has been working on a structural code change that we’ll be rolling out to Firefox 2 and IE 7 users over the coming weeks (with other browsers to follow). You won’t notice too many differences to start with, but we’re using a new model that enables us to iterate faster and share components (we now use the same rich text editor as Groups and Page Creator, and the Contact Manager can be seen in several Google apps). A few other things you will notice are some new keyboard shortcuts and the ability to bookmark specific messages and email searches.

The outcome is great and some of the stuff that they did really inspires me (should be to all developers out there)

This should go on to every developer’s best practices list:

We have also been fanatical about speed. Even on a fast Internet connection, it can take a second to request and render a new web page, and when you read a lot of mail, these seconds can accumulate to hours waiting for email to load. We’ve spent a lot of time profiling all parts of the application, shaving milliseconds off wherever we can, and figuring out workarounds for some pretty deep-rooted issues with the current browser implementations. Some of the most common actions should be faster now.

Aaron Boodman of Greasemonkey and Gears fame also wrote:

At Google, we dogfood all our products. That means, among other things, that we use Gmail all day for all our internal mail. I don’t know of any other company producing web mail that can claim that. It also means that we have really high standards for these products. 500ms latency is usually considered great for a web application, but for something you use all day, it just won’t cut it. Because of this, the Gmail team has been to hell and back several times over the course of this project, trying to shave milliseconds off frequent operations.

Personally, i’ve heard from more than one person complaining about how Gmail’s loading speed is getting worse and worse. To me, it was a nightmare if Gmail was left on for a long time and you come back to it, it was just SLOW. I noticed the facelift before i found this article on Ajaxian.com. How I realized was actually through Firebug. Here’s a screenshot.

Checkout the “FIX”

Firebug can make Gmail slow

If you’re using Windows or Linux

For the best Gmail performance, we suggest disabling Firebug for www.google.com by following these steps:

1. Click the green or red icon in the bottom right corner of the browser window to open Firebug.
2. Click the bug icon in the top left corner of Firebug and select ‘Disable Firebug for mail.google.com.’

If you’d like to keep Firebug running, you may improve Gmail performance by following these steps:

1. Click the green or red icon in the bottom right corner of the browser window to open Firebug.
2. Click the Console tab.
3. Select Options.
4. Uncheck Show XMLHttpRequests.
5. Click the Net tab.
6. Select Options.
7. Check Disable Network Monitoring.

If you’re using a Mac

Please note that if you’re using a Mac, you’ll continue to experience performance problems unless you disable Firebug for Gmail. To disable Firebug for www.google.com, please follow the steps below:

1. Click the green or red icon in the bottom right corner of the browser window to open Firebug.
2. Click the bug icon in the top left corner of Firebug and select ‘Disable Firebug for mail.google.com.’

If disabling Firebug for Gmail doesn’t improve performance results, you may have to entirely disable Firebug.

TinyMCE 3 - Alpha 1 Release

Got WYSIWYG?

If you know what WYSIWYG, you probably know about TinyMCE, one of the most popular WYSIWYG out there developed by Moxie Code

This build is purely a performance based. As stated in their description:

From a pure feature point of view, this release might not be very impressive, but if you are interested in JavaScript and do a lot of custom development, this is the release you have been waiting for. One of the main focuses for the new 3.x branch is to produce a more powerful API and also make it output valid XHTML code by default.

With the list of items improved in this release, personally i think it’s a win for everyone who’s implementing TinyMCE, doesn’t matter what the purpose is.

* Rewrote the core and most of the plugins and themes from scratch.
* Reduced the over all script size by 33% and the number of files/requests by 75% so it loads a lot faster.
* Added new and improved serialization engine, faster and more powerful.
* Added new inlinepopups plugin, the dialogs are now skinnable and uses clearlooks2 as default.
* Added new contextmenu plugin, context menus can now have submenus and plugins can add items on the fly.
* Added new skin support for the simple and advanced themes you can alter the whole UI using CSS.
* Added new o2k7 skin for the simple and advanced themes.
* Added new JSON parser/serializer and JSON-RPC class to the core API.
* Added new cookie utility class to the core API.
* Added new Unit testing class to the core API only available in dev mode.
* Added new Safari plugin, fixes lots compatibility of issues with Safari 3.x.
* Added new on demand loading of plugins and themes. Enables you to load and init TinyMCE at any time.
* Added new unit tests in the dev package of TinyMCE. Runs tests on the core API, commands and settings of the editor.
* Removed all button images and replaced them with CSS sprite images. Reduces the number of requests needed.
* Removed lots of language files and merged them into the base language files. Reduces the number of requests needed.
* Removed lots of unnecessary files and merged many of them together to reduce requests and improve loading speed.
* Fixed so convert_fonts_to_spans are enabled by default. So no more font tags.
* Fixed so all classes from @import stylesheets gets imported into the editor.

Another thing that might not be recognized yet is the overall fixes for Safari 3. If you have been using the older version of TinyMCE, try it out on Safari 3 and almost nothing works there.

Also, the popup windows are replaced with floating popups within the page to prevent the popup blocker from breaking the user experience.

Full Article can be found here http://tinymce.moxiecode.com/punbb/viewtopic.php?id=8959

Full Featured demo: http://tinymce.moxiecode.com/example_skin.php?example=true

A few thoughts of mine:

1. By looking at the demo, it feels like it is even slower now when the WYSIWYG gets initialized.

2. As usual, there are way too many features packed into it and getting rid of them can be a pain (maybe i’m wrong since it’s a new release)

3. “Added new on demand loading of plugins and themes. Enables you to load and init TinyMCE at any time.” This is definitely a plu. I can’t remember how many hours i’ve put in to allow more than one session of TinyMCE to be initiated within the same page (through Ajax).

It is really cool to see the guys over at Moxie Codes are working so hard to keep this awesome WYSIWYG alive. And yes, it’s about time for it to get a major core improvement :) Thanks TinyMCE team.

Bored Rogue Jumping Tables

Sigh… these ppl are bored as hell…




Close
E-mail It