7 awesome JavaScript projects to check out today

Here are seven newer JavaScript projects you might not know about yet. These tools and frameworks cover a wide range of functionality and give us insight into emerging trends in JavaScript development. Examples include native app creation, strongly typed full-stack development, a drop-in runtime alternative to Node.js, in-browser graphics, and more. All of the projects are currently being embraced by developers, so they may not be under the radar for long. Just remember, you heard about them here first!

Tauri: A JavaScript framework for desktop apps

Tauri is a JavaScript framework for building desktop applications. Perhaps “meta-framework” is a better term. It allows you to use any front-end web framework, like React or Svelte, and turn it into a cross-platform “rich” client.

Denjell, a co-founder of Tauri, shared a bit about the incentive for developing a new desktop framework.

Tauri exists to streamline the process of building apps. So if someone is interested in building apps, they might stumble across Tauri. First of all, Tauri builds apps for Mac, Windows, and Linux. This summer, we will release a stable 2.0 that introduces iOS and Android to the mix, as well.

The development process for Tauri is quite interesting. The framework lets you build with the existing pipeline you are using, for example, SvelteKit built with Vite. Tauri can handle any stack that ultimately builds to JavaScript and HTML. It runs against the development server, generating the native desktop client for you as you go.

Denjell describes the development process as follows:

  1. Start a dev server using Svelte, Solid.js, React, Vue, etc.

  2. Configure tauri.conf to listen at that port.

  3. Start a Tauri dev window.

Although Tauri’s code is systems-oriented and built in Rust, developers interact with APIs that are almost all written in JavaScript. Tauri is a compelling approach to building native desktop applications for the universe of JavaScript developers. Unlike older frameworks that attempted similar feats, Tauri looks to deliver on the promise of multiplatform development using JavaScript.

tRPC: API development with TypeScript

tRPC is an alluring approach to building APIs backed by TypeScript. While it's in the same family of technologies as GraphQL, tRPC is different in that it automates the interaction between the front- and back-end code. It also has superpowers derived from TypeScript’s ability to enforce typing.

I asked tRPC creator Alex Johansson why he created tRPC.

I am a longtime fan of GraphQL (and still am) but when building my own products I often feel like it slowed me down—I was using TypeScript on both ends. Why can't I just use the language itself rather than bringing in an external schema?

tRPC's superpower is using what’s already there to support enforcement and association of types across the whole stack. It provides a kind of two-way type inference, and makes it work without the intermediary of metadata or an extra build step to tie the API definitions to the consuming code. When I grokked what tRPC was about, I had a feeling of simplicity suggestive of genius.

Here is a live full-stack React app built by the tRPC team using StackBlitz. tRPC provides the endpoints and the whole thing is quite simple, with just a handful of files required. Simple is good.

In the StackBlitz example, the exposed endpoints drive the information the IDE has available. For example, on the front end, the result variable is populated using a custom tRPC useQuery hook like so: const result = trpc.greeting.useQuery({ name: 'client' });. On the back end, this is handled by a tRPC router.

The front end is then able to use the variable like so: {result.data.text}. The IDE (and TypeScript compilation step) is fully aware and able to supply the type definition of result.data. Likewise, the tRPC router endpoint is aware of the front end, for example, the parameter supplied in the query.

Overall, tRPC is a unique and enticing way to build full-stack TypeScript applications. It is gaining increasing interest from the developer community, with close to 20,000 stars on GitHub as of this writing.

READ MORE