Microsoft is releasing version 1.93 of Visual Studio Code (VS Code), the most widely used programmer’s editor and lightweight IDE, and along with the usual raft of new features the team says it has completed most of the work to adopt ESM (ECMAScript modules) in place of the older AMD (Asynchronous Module Definition) standard.
ESM is native to modern browsers but AMD is a long-running standard which predates ESM. Microsoft software engineer Benjamin Pasero reported that “we are now able to build a ESM variant of VS Code with a build flag that will run a migration script.” This script converts the source code, which is mainly TypeScript, into an ESM-compatible format. The goal said Pasero, “is to ship ESM enabled Insiders in September and stable in October,” where Insiders is the pre-release version of VS Code that is one month or so ahead of the stable release.
The approach is cautious and there will be a way of converting the code back to AMD if the ESM build proves problematic. If the stable October release works without major issues, “we begin removing AMD traces from our sources and remove the option to build VS Code as AMD,” Pasero said.
While the goal of this migration is to be mostly invisible to developers, it is significant that this large codebase and major project is making this migration and may help accelerate the slow general adoption of ESM.
An intriguing feature of version 1.93, also known as the August release, is that it includes a fix for improperly describing the language of SQL Server as SQL. VS Code is a Microsoft product, and a distribution of the open source Code – OSS, and despite its popularity across many languages and platforms, there are areas where Microsoft-specific defaults or features can be confusing.
One of those is SQL (structured query language) where VS Code’s syntax highlighting does not always work as expected with files that have a .sql extension. An example from last week is this issue: “SQL format not highlighting ‘qualify’ statement.”
The issue was closed with “as-designed” because as stated here by senior software engineer Charles Gagnon, “VS Code has adopted this [MS SQL (T-SQL)] grammar as the base ‘sql’ grammar.” T-SQL stands for Transact SQL and is the extension of SQL developed by Sybase and Microsoft for SQL Server. PostgreSQL has its own language extensions, as does Oracle SQL, MySQL, SQLite and so on.
There is a small change in VS Code 1.93 which is that T-SQL is now correctly described as MS SQL, as indicated in the bottom right corner when a .sql file is open with the default setting. Previously it just stated SQL. As before, click on this identifier or install an extension which understands the dialect of SQL in use and the file association can be changed.
There is plenty more in the 1.93 release. One is that the improved user interface for the profiles editor, previously experimental, is now on by default. Profiles allow developers to configure settings, extensions, view layout, keybindings, code snippets and tasks, save them under a profile name, and switch between profiles for different types of work.
Django developers will be pleased to find that Django unit tests can now be discovered and run through the VS Code Test Explorer. This functionality was first requested in 2017, demonstrating that the process for getting an issue resolved can be a lengthy one.
The browser-hosted version of VS Code has been improved with package IntelliSense, meaning pop-up documentation and code completion for imported packages such as react. Microsoft has also implemented full IntelliSense for JavaScript and TypeScript projects, which means that “Go to Definition” and “Find all references” now work as expected. That said, this feature only works in Chrome, Edge and Firefox; Apple’s Safari is not supported because of the requirement for a browser API called ReadableByteStreamController – bad news for developers working from an iPad, for example.
A handy feature for JavaScript developers is a new experimental network view to show requests and responses, which works with browser sessions and to some extent with Node.js 22.6 and higher. There is a warning though that work with Node requires an –experimental-network-inspection flag when launching Node, and even then, that “Node’s implementation of networking is still very early and most data around requests and responses is not yet available.”
Full details of what is new in 1.93 are in the release notes.