Workbench 47
A new release of Workbench is available.
As the release version indicates; it now uses the GNOME SDK 47.
Roland Lötscher added an action to create a new blank project.
Experimental TypeScript support
Thanks to GSoC student Angelo Verlain (aka vixalien); we now have experimental TypeScript support. See their blog post for details.
What works
- Compile and Run TypeScript code
- Diagnostics
- Code Suggestions / Completions
What's missing
- Porting Library entries to TypeScript work-in-progress
- Accurate stack traces; possible in GNOME 48 thanks to source map support in GJS
- Async API in GJS to fix type diagnostics work-in-progress
Code suggestions / completions
It makes use of respective language servers. Only Blueprint and TypeScript have support so far.
Permissions
The goal of Workbench has always been to be fully sandboxed to reduce the risk of running code that would harm the user or the system.
Over time and as the Library covered more and more desktop integration examples, we made exceptions for --share=network
(for HTTP/WebSocket) and --socket=pulseaudio
(for audio playback).
A new Library entry “Gamepad” by GSoC 2023 student José Hunter would have required us to add --device=all
. This would have been too risky; in particular for beginners.
I took the time to remove the problematic permissions and add a dialog that request user action when sandbox permissions are required
Thanks to Brage Fuglseth for the design.
If you are tempted to do this in your apps, please don't. This is a temporary measure until we get the appropriate Flatpak permissions or portals to handle these safely.
While imperfect, in the case of Workbench which targets beginners and can be used to execute any code; it is better than opening sandbox holes by default.
Before:
After:
Library
GSoC student Bharat Tyagi added Language and Category filters to the Library
As usual, many improvements were made to the demos
7 new demos
- Add “Button Row” demo
- Add “Gamepad” demo
- Add “List View with Sections” demo
- Add “List View with a Tree” demo
- Add “Bottom Sheet” demo
- Add “Database” demo
- Update “Spinner” to use AdwSpinner
3 demos ported to Python
- Port “Dialog” to Python
- Port “List View” to Python
- Port “Grid View” to Python
7 demos ported to Rust
- Port “Level Bars” to Rust
- Port “Text Fields” to Rust
- Port “Column View” to Rust
- Port “Clamp” to Rust
- Port “List View” to Rust
- Port “Frame” to Rust
- Port “Audio” to Rust
25 demos ported to Vala
- Port “File Monitor” to Vala
- Port “Scrolled Window” to Vala
- Port “Menu” to Vala
- Port “HTTP Server” to Vala
- Port “Map” to Vala
- Port “Session Monitor and Inhibit” to Vala
- Port “Save File” to Vala
- Port “Spin Button” to Vala
- Port “Progress Bar” to Vala
- Port “Label” to Vala
- Port “Power Profile Monitor” to Vala
- Port “Drawing Area” to Vala
- Port “Font Dialog” to Vala
- Port “Select Folder” to Vala
- Port “Network Monitor” to Vala
- Port “Toggle Button” to Vala
- Port “Tooltip” to Vala
- Port “Spell Checker” to Vala
- Port “Popovers” to Vala
- Port “Menu Button” to Vala
- Port “Frame” to Vala
- Port “Actions” to Vala
- Port “Dialog” to Vala
- Port “CSS Gradients” to Vala
- Port “Snapshot” to Vala