Skip to content

Commit 4391f88

Browse files
committed
Update references to the latest tech stack plans
1 parent 00cfa07 commit 4391f88

File tree

14 files changed

+15
-51
lines changed

14 files changed

+15
-51
lines changed

.github/workflows/build-dev-and-ci.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,9 @@ jobs:
4848
rustc --version
4949
5050
- name: ✂ Replace template in <head> of index.html
51-
if: github.ref != 'refs/heads/master'
52-
env:
53-
INDEX_HTML_HEAD_REPLACEMENT: ""
5451
run: |
5552
# Remove the INDEX_HTML_HEAD_REPLACEMENT environment variable for build links (not master deploys)
53+
git rev-parse --abbrev-ref HEAD | grep master > /dev/null || export INDEX_HTML_HEAD_REPLACEMENT=""
5654
sed -i "s|<!-- INDEX_HTML_HEAD_REPLACEMENT -->|$INDEX_HTML_HEAD_REPLACEMENT|" frontend/index.html
5755
5856
- name: 🌐 Build Graphite web code

.nix/flake.nix

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,19 @@
11
# This is a helper file for people using NixOS as their operating system.
22
# If you don't know what this file does, you can safely ignore it.
3-
# This file defines both the development environment for the project.
3+
# This file defines the reproducible development environment for the project.
44
#
55
# Development Environment:
6-
# - Provides all necessary tools for Rust/WASM development
7-
# - Includes Tauri dependencies for desktop app development
6+
# - Provides all necessary tools for Rust/Wasm development
87
# - Sets up profiling and debugging tools
98
# - Configures mold as the default linker for faster builds
109
#
11-
#
1210
# Usage:
1311
# - Development shell: `nix develop`
1412
# - Run in dev shell with direnv: add `use flake` to .envrc
1513
{
1614
description = "Development environment and build configuration";
1715

1816
inputs = {
19-
# This url should be changed to match your system packages if you work on tauri because you need to use the same graphics library versions as the ones used by your system
2017
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
2118
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
2219
rust-overlay = {
@@ -96,7 +93,6 @@
9693
pkgs.pkg-config
9794
pkgs.git
9895
pkgs.gobject-introspection
99-
pkgs-unstable.cargo-tauri
10096
pkgs-unstable.cargo-about
10197

10298
# Linker

editor/src/node_graph_executor/runtime_io.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use super::*;
22
use std::sync::mpsc::{Receiver, Sender};
33

4-
/// Handles communication with the NodeRuntime, either locally or via Tauri
4+
/// Handles communication with the NodeRuntime
55
#[derive(Debug)]
66
pub struct NodeRuntimeIO {
77
// Send to

frontend/README.md

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
# Overview of `/frontend/`
22

3-
The Graphite frontend is a web app that provides the presentation for the editor. It displays the GUI based on state from the backend and provides users with interactive widgets that send updates to the backend, which is the source of truth for state information. The frontend is built out of reactive components using the [Svelte](https://svelte.dev/) framework. The backend is written in Rust and compiled to WebAssembly (WASM) to be run in the browser alongside the JS code.
4-
5-
For lack of other options, the frontend is currently written as a web app. Maintaining web compatibility will always be a requirement, but the long-term plan is to port this code to a Rust-based native GUI framework, either written by the Rust community or created by our project if necessary. As a medium-term compromise, we may wrap the web-based frontend in a desktop webview windowing solution like Electron (probably not) or [Tauri](https://tauri.app/) (probably).
3+
The Graphite frontend is a web app that provides the presentation for the editor. It displays the GUI based on state from the backend and provides users with interactive widgets that send updates to the backend, which is the source of truth for state information. The frontend is built out of reactive components using the [Svelte](https://svelte.dev/) framework. The backend is written in Rust and compiled to WebAssembly (Wasm) to be run in the browser alongside the JS code.
64

75
## Bundled assets: `assets/`
86

@@ -18,15 +16,15 @@ Source code for the web app in the form of Svelte components and [TypeScript](ht
1816

1917
## WebAssembly wrapper: `wasm/`
2018

21-
Wraps the editor backend codebase (`/editor`) and provides a JS-centric API for the web app to use unburdened by Rust's complex data types that are incompatible with JS data types. Bindings (JS functions that call into the WASM module) are provided by [wasm-bindgen](https://rustwasm.github.io/docs/wasm-bindgen/) in concert with [wasm-pack](https://github.com/rustwasm/wasm-pack).
19+
Wraps the editor backend codebase (`/editor`) and provides a JS-centric API for the web app to use as an entry point, unburdened by Rust's complex data types that are incompatible with JS data types. Bindings (JS functions that call into the Wasm module) are provided by [wasm-bindgen](https://rustwasm.github.io/docs/wasm-bindgen/) in concert with [wasm-pack](https://github.com/rustwasm/wasm-pack).
2220

23-
## ESLint configurations: `.eslintrc.js`
21+
## ESLint configurations: `.eslintrc.cjs`
2422

2523
[ESLint](https://eslint.org/) is the tool which enforces style rules on the JS, TS, and Svelte files in our frontend codebase. As it is set up in this config file, ESLint will complain about bad practices and often help reformat code automatically when (in VS Code) the file is saved or `npm run lint` is executed. (If you don't use VS Code, remember to run this command before committing!) This config file for ESLint sets our style preferences and configures our usage of extensions/plugins for Svelte support and [Prettier](https://prettier.io/)'s role as a code formatter.
2624

2725
## npm ecosystem packages: `package.json`
2826

29-
While we don't use Node.js as a JS-based server, we do have to rely on its wide ecosystem of packages for our build system toolchain. If you're just getting started, make sure to install the latest LTS copy of Node.js. Our project's philosophy on third-party packages is to keep our dependency tree as light as possible, so adding anything new to our `package.json` should have overwhelming justification. Most of the packages are just development tooling (TypeScript, Vite, ESLint, Prettier, wasm-pack, and [Sass](https://sass-lang.com/)) that run in your console during the build process.
27+
While we don't use Node.js as a JS-based server, we do rely on its ecosystem of packages for our build system toolchain. If you're just getting started, make sure to install the latest LTS copy of [Node.js](https://nodejs.org/en/download). Our project's philosophy on third-party packages is to keep our dependency tree as light as possible, so adding anything new to our `package.json` should have overwhelming justification. Most of the packages are just development tooling (TypeScript, Vite, ESLint, Prettier, and [Sass](https://sass-lang.com/)) that run in your terminal during the build process.
3028

3129
## npm package installed versions: `package-lock.json`
3230

@@ -36,6 +34,6 @@ Specifies the exact versions of packages installed in the npm dependency tree. W
3634

3735
Basic configuration options for the TypeScript build tool to do its job in our repository.
3836

39-
## Vite configurations: `vite.config.js`
37+
## Vite configurations: `vite.config.ts`
4038

4139
We use the [Vite](https://vitejs.dev/) bundler/build system. This file is where we configure Vite to set up plugins (like the third-party license checker/generator). Part of the license checker plugin setup includes some functions to format web package licenses, as well as Rust package licenses provided by [cargo-about](https://github.com/EmbarkStudios/cargo-about), into a text file that's distributed with the application to provide license notices for third-party code.

frontend/src/utility-functions/keyboard-entry.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ export function textInputCleanup(text: string): string {
3232
// <https://github.com/WICG/keyboard-map/issues/26>
3333
// In the desktop version of VS Code, this is achieved with this Electron plugin:
3434
// <https://github.com/Microsoft/node-native-keymap>
35-
// We may be able to port that (it's a relatively small codebase) to Rust for use with Tauri.
35+
// We may be able to port that (it's a relatively small codebase) to Rust for use with our desktop application.
3636
// But on the web, just like VS Code, we're limited by the shortcomings of the spec.
3737
// A collection of further insights:
3838
// <https://docs.google.com/document/d/1p17IBbYGsZivLIMhKZOaCJFAJFokbPfKrkB37fOPXSM/edit>

libraries/path-bool/shell.nix

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,13 +59,6 @@ in
5959
samply
6060
cargo-flamegraph
6161

62-
# For Tauri
63-
openssl
64-
glib
65-
gtk3
66-
libsoup
67-
webkitgtk
68-
6962
# For Rawkit tests
7063
libraw
7164

node-graph/graph-craft/src/wasm_application_io.rs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,14 +70,6 @@ pub struct WasmApplicationIo {
7070
static WGPU_AVAILABLE: std::sync::atomic::AtomicI8 = std::sync::atomic::AtomicI8::new(-1);
7171

7272
pub fn wgpu_available() -> Option<bool> {
73-
// Always enable wgpu when running with Tauri
74-
#[cfg(target_arch = "wasm32")]
75-
if let Some(window) = web_sys::window() {
76-
if js_sys::Reflect::get(&window, &wasm_bindgen::JsValue::from_str("__TAURI__")).is_ok() {
77-
return Some(true);
78-
}
79-
}
80-
8173
match WGPU_AVAILABLE.load(Ordering::SeqCst) {
8274
-1 => None,
8375
0 => Some(false),

website/content/blog/2024-01-01-looking-back-on-2023-and-what's-next.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ And then from a development perspective, I am looking forward to accomplishing t
166166

167167
- Restoring several previous features that were removed during refactors in the past year to a fully working state including Imaginate, snapping, folder bounding boxes, transform pivots, and vector shape boolean operations
168168
- Deploying GPU-based rendering by default and moving from an experimental to a production-ready hardware-accelerated compositing system using [Vello](https://github.com/linebender/vello) to unify the currently separate raster and vector pipelines
169-
- Shipping desktop apps for Windows, Mac, and Linux by integrating [Tauri](https://tauri.app/) and bundling built-in AI models to run Imaginate and other upcoming features directly on user hardware
169+
- Shipping desktop apps for Windows, Mac, and Linux and bundling built-in AI models to run Imaginate and other upcoming features directly on user hardware
170170
- Designing a new vector graphics data format suitable for advanced procedural editing and rendering, plus the associated procedural workflow features
171171
- Remaking the Brush tool with the GPU-accelerated pipeline and the adaptive resolution system so digital painting in Graphite becomes practical
172172
- Implementing the Mask Mode feature for Magic Wand tool marquee selections, which will dramatically improve Graphite's utility as a raster graphics editor

website/content/blog/2025-01-16-year-in-review-2024-highlights-and-a-peek-at-2025.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ There are so many plans that I'm eager to carry out to improve the clarity and c
173173

174174
Starting out with our most in-demand request: a desktop app. This has been on our roadmap from the start but only recently it's begun making sense putting it at the front of the roadmap priorities. We hoped to complete it by the end of 2024, but that wasn't in the cards due to developer availability and the specialized skills needed to complete the task.
175175

176-
Now to get technical, the lazy option exists: chucking the whole web app in an unaltered Electron wrapper, but this is a technological dead end that I believe offers no value compared to a PWA. The value comes from offering an actual native app where the editor Rust code and GPU-accelerated rendering runs on a user's Windows, Mac, or Linux machine without browser overhead. <a href="https://tauri.app/" target="_blank">Tauri</a> provides this capability, but our use case presents some unsupported challenges that our team has to overcome— individually on each platform. The natively rendered viewport content must be composited with the rest of the Tauri window's editor GUI. When investigating this earlier in the year, this isn't properly supported and we will have to develop solutions to fix Tauri's use of the OS platform APIs. If you have experience with native development on Windows, Mac, and/or Linux, please get involved to speed up this effort! With our current resources, I am anticipating this will be ready for release around spring.
176+
Now to get technical, the lazy option exists: chucking the whole web app in an unaltered Electron wrapper, but this is a technological dead end that I believe offers no value compared to a PWA. The value comes from offering an actual native app where the editor Rust code and GPU-accelerated rendering runs on a user's Windows, Mac, or Linux machine without browser overhead. Our use case of combining the web-rendered editor interface with the user's native-rendered artwork presents several unique challenges that our team has to overcome— individually on each platform. If you have experience with native development on Windows, Mac, and/or Linux, please get involved to speed up this effort! With our current resources, I am anticipating this will be ready for release around spring.
177177

178178
### Animation
179179

website/content/blog/2025-04-02-internships-for-a-rust-graphics-engine-gsoc-2025.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ Out of the [full list of project opportunities](/volunteer/guide/student-project
4141
- Creating an efficient brush rendering system for large painted path datasets
4242
- Managing colors through flexible use of color spaces, color models, and color profiles
4343
- Researching an assortment of algorithms for image processing operations
44-
- Engineering solutions for combining Tauri's webview and Graphite's WGPU renderer in the same window across Windows, Mac, and Linux desktop applications
44+
- Engineering solutions for combining our web-based editor GUI and native WGPU renderer in the same window across Windows, Mac, and Linux desktop applications
4545

4646
These recently added projects are pending an extended description, but we'll be happy to discuss the details if you pop into our [Discord server](https://discord.graphite.rs) and introduce yourself with links to related experience and projects.
4747

0 commit comments

Comments
 (0)