Agent Skills: tauri-app-localhost

Serve your Tauri v2 frontend via a localhost server using the localhost plugin for frameworks requiring a server. Use when your frontend framework needs a local HTTP server, separating dev/production localhost behavior, or controlling port exposure.

UncategorizedID: teachingai/full-stack-skills/tauri-app-localhost

Install this agent skill to your local

pnpm dlx add-skill https://github.com/partme-ai/full-stack-skills/tree/HEAD/skills/tauri-skills/tauri-app-localhost

Skill Files

Browse the full folder contents for tauri-app-localhost.

Download Skill

Loading file tree…

skills/tauri-skills/tauri-app-localhost/SKILL.md

Skill Metadata

Name
tauri-app-localhost
Description
"Serve your Tauri v2 frontend via a localhost server using the localhost plugin for frameworks requiring a server. Use when your frontend framework needs a local HTTP server, separating dev/production localhost behavior, or controlling port exposure."

When to use this skill

ALWAYS use this skill when the user mentions:

  • Serving frontend via localhost in a Tauri app
  • Local server exposure and port configuration
  • Dev vs production localhost behavior differences

Trigger phrases include:

  • "localhost", "local server", "localhost plugin", "port", "serve frontend"

How to use this skill

  1. Install the localhost plugin:
    cargo add tauri-plugin-localhost
    
  2. Register the plugin with a specific port in your Tauri builder:
    tauri::Builder::default()
        .plugin(tauri_plugin_localhost::Builder::new(3030).build())
    
  3. Configure the frontend URL in tauri.conf.json for production:
    { "build": { "frontendDist": "../dist" } }
    
  4. Bind only to 127.0.0.1 to prevent external access to the local server
  5. Separate dev-mode access (Vite dev server on port 5173) from production (localhost plugin on a fixed port)
  6. Audit access patterns to ensure minimal exposure in production builds

Outputs

  • Localhost plugin configuration with fixed port
  • Dev vs production server separation
  • Security checklist for minimal exposure

References

  • https://v2.tauri.app/plugin/localhost/

Keywords

tauri localhost, local server, port, serve frontend, dev server