Skip to content

JamieMaclean/tauri-specta

 
 

Repository files navigation

Specta Logo

Tauri Specta

Typesafe Tauri commands

Discord crates.io License

This branch contains code + examples for tauri-specta v2. You can check the v1.0.2 git tag for the v1 code + examples.

Getting Started

For most use cases, you'll probably want to use v1, which is stable.

You can also use v2 which supports generating types for events and utilises Specta v2, but both it and Specta v2 are still in development.

Known limitations

  • Your command can only take up to 10 arguments. Any more and you'll get a compile error. If you need more just use a struct.
  • Exporting your schema within a directory tracked by Tauri's hot reload will cause an infinite reload loop.

Development

Run the example:

pnpm i
cd examples/app/
pnpm dev

Credit

Created by oscartbeaumont and Brendonovich.

About

Completely typesafe Tauri commands

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Rust 91.0%
  • TypeScript 4.5%
  • JavaScript 4.5%