From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ted Zlatanov Newsgroups: gmane.emacs.devel Subject: Re: another javascript mode Date: Thu, 10 Apr 2008 09:21:49 -0500 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: <86bq4h6b9e.fsf@lifelogs.com> References: <200804091804.m39I4Pbt025532@sallyv1.ics.uci.edu> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1207837312 11041 80.91.229.12 (10 Apr 2008 14:21:52 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 10 Apr 2008 14:21:52 +0000 (UTC) Cc: steve.yegge@gmail.com To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Apr 10 16:22:24 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JjxdK-0000Wl-UQ for ged-emacs-devel@m.gmane.org; Thu, 10 Apr 2008 16:20:11 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Jjxcg-00043t-GC for ged-emacs-devel@m.gmane.org; Thu, 10 Apr 2008 10:19:30 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Jjxcb-00043G-Je for emacs-devel@gnu.org; Thu, 10 Apr 2008 10:19:25 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JjxcY-000412-ST for emacs-devel@gnu.org; Thu, 10 Apr 2008 10:19:24 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JjxcY-00040r-8b for emacs-devel@gnu.org; Thu, 10 Apr 2008 10:19:22 -0400 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JjxcX-0006Y3-NJ for emacs-devel@gnu.org; Thu, 10 Apr 2008 10:19:21 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1JjxcT-00053l-4m for emacs-devel@gnu.org; Thu, 10 Apr 2008 14:19:17 +0000 Original-Received: from 38.98.147.130 ([38.98.147.130]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 10 Apr 2008 14:19:17 +0000 Original-Received: from tzz by 38.98.147.130 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 10 Apr 2008 14:19:17 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 43 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 38.98.147.130 X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6; d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" User-Agent: Gnus/5.110007 (No Gnus v0.7) Emacs/23.0.60 (gnu/linux) Cancel-Lock: sha1:pSs4zA/DW6XltTN1TjR/arLrtAM= X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:94871 Archived-At: On Wed, 09 Apr 2008 11:04:25 -0700 Dan Nicolaescu wrote: DN> A new javascript mode was posted here: DN> http://code.google.com/p/js2-mode/ DN> We were looking to include a mode for javascript, from the description DN> this mode seems to be a better candidate for inclusion. DN> Can someone that uses javascript check it out please? cc-ing Steve Yegge in case he wants to comment... I do Javascript work and installed js2-mode when it was released. My initial comments are on http://code.google.com/p/js2-mode/wiki/Discussion and the author addressed them. - the built-in parser is good at catching most common mistakes, especially leaving a trailing comma in a list (very annoying since some browsers accept it). This is really, really nice. - the indentation guessing (every TAB indents to a different possible offset) is annoying to me, even with the patch to require two TABs after the first one. It's inconsistent with what Emacs does in all other modes, IMO. I'd rather take the first guess (and improve the code. if it's no good) and invoke subsequent guesses with a secondary indent command. - the pre-compilation requirement is a bit annoying. I understand the idea, but wish it could be automatic. - it can't currently integrate with mmm-mode, I often need to switch from HTML to Javascript to CSS in a typical web page. Steve Yegge says it's not easy in the discussion URL above. Someone suggested mumamo, but I haven't tried that yet. - auto-update won't be too important if it becomes part of Emacs Overall, I'd rather use js2-mode than anything else I've tried (and I've tried at least 4 Javascript modes), primarily for the error highlighting and the good indentation. I hope it can go into Emacs. Ted