An exciting new feature that shipped with Visual Studio Code 1.44 is support for Custom Editors.
The true power behind Custom Editors is the fact that these editors have both read and write support, and offer way more than simply “an alternate view of a certain file type”. Changes in the original source file are immediately reflected in the custom editor, and vice versa.
I’m quite excited for the Custom Text Editors feature, as it opens up a ton of possibilities. Here’s a few examples the docs hint at:
Previewing assets, such as shaders or 3D models, directly in VS Code.
Creating WYSIWYG editors for languages such as Markdown or XAML.
Offering alternative visual renderings for data files such as CSV or JSON or XML.
Building fully customizable editing experiences text files.
An example editor is vscode-asciiflow2, a tool to easily draw ASCII diagrams. Thanks to the Custom Editor API it can be used directly inside of Visual Studio Code
To get started with creating your own Custom Editor, be sure to check this video:
💁♂️ For a project I’m working on I’ve created a “Pump Configurator” in React. It allows a user to visually define the tanks and pumps layout of a Petrol Station (see video below). The generated configuration is stored as JSON. If we wanted, we could use the Custom Editors API to bring this editor into VS Code.
GitLens supercharges the Git capabilities built into Visual Studio Code. It helps you to visualize code authorship at a glance via Git blame annotations and code lens, seamlessly navigate and explore Git repositories, gain valuable insights via powerful comparison commands, and so much more.
Just installed it and must say it’s really nice. Here’s an introductory video walking you through the extension:
I spent a lot of time combing the depths of the VS Code Extension Marketplace to find the tastiest and most delicious extensions that are guaranteed to make your life as a React developer 129% more enjoyable. All you have to do is install the React Food Truck extension and it will automatically install my handpicked extension smorgasbord.