From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Steinar Bang Newsgroups: gmane.emacs.help Subject: JavaScript/TypeScript: What do people in 2024, on emacs 29, use for .js, .jsx, .ts and .tsx? Date: Tue, 09 Jan 2024 13:12:15 +0100 Message-ID: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="2771"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jan 09 13:13:06 2024 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rNAyg-0000Z1-0n for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 09 Jan 2024 13:13:06 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rNAyA-0005O5-Iv; Tue, 09 Jan 2024 07:12:34 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rNAy8-0005Nv-PC for help-gnu-emacs@gnu.org; Tue, 09 Jan 2024 07:12:32 -0500 Original-Received: from schwantz.bang.priv.no ([95.217.129.251]) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rNAy6-00031n-6J for help-gnu-emacs@gnu.org; Tue, 09 Jan 2024 07:12:32 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=dod.no; s=sb; t=1704802333; bh=VVG9QMR78aEvlGkDl2Z3pblWnZwjz197+1JdYdjxbDQ=; h=From:To:Subject:Date:From; b=JPF9e199OQNwl7EZu8pFTzf27AB7obGFctWVX6G9P0VMl5KYpbI9XJAe+sV5BA3/k c8D6nXv+YYz5D3UvMn6wDZXrjcp00/G2xUCNTGDOBU9jauzz4CYEQZVqAsrG/HxA2O IgVg05fEhIvisUN/skZs7s/7Ri1CutzjCaQwi9T4= Original-Received: from AAP-5CG32757DH (steria10.steria.no [195.204.41.10]) by schwantz.bang.priv.no (Postfix) with ESMTPSA id 587653B4 for ; Tue, 9 Jan 2024 12:12:13 +0000 (UTC) Received-SPF: none client-ip=95.217.129.251; envelope-from=sb@dod.no; helo=schwantz.bang.priv.no X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:145704 Archived-At: I'm in the process of setting up a new windows laptop, and have installed Emacs 29. I have been using rjsx-mode for react.js JSX files since 2018, so I routinely started installing that from melpa. But then I noticed that it was kinda old: The version on melpa is from February 24 2020. And looking at rjsx-mode's github page the last commit was October 28 2020: https://github.com/felipeochoa/rjsx-mode So I decided to see what came up as default on emacs 29. What I get according to 'C-h m', is: The major mode is JavaScript[JSX] mode defined in js.el: JSX tag syntax seems to be highlighted correctly and indentations seems to be correct (I'm using https://github.com/editorconfig/editorconfig-emacs ). But there doesn't seem to be the same electric tag splitting behaviour I have on JSX mode...? Though that may be a configuration possibility...? What do others use? And what about typescript? I don't like typescript so I don't use that in any of my private projects, but when working with frontends I have to adapt. Last time I worked with typescript (2021-2022) I think I ended up with something called tide and web-mode for the .ts and .tsx files, while staying with rjsx-mode for .js and .jsx files. I don't know if that's still the way to go for typescript or if the built-in javascript mode now handles typescript? What do others use? Thanks! - Steinar