devtools-production

Exclude or conditionally include TanStack Devtools in production builds via Vite plugins.

485|92|Updated Jul 25, 2025
One-click install
npx skills add https://github.com/TanStack/devtools --skill devtools-production
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: devtools-production
Source: https://github.com/TanStack/devtools/tree/main/packages/devtools/skills/devtools-production
Command: npx skills add https://github.com/TanStack/devtools --skill devtools-production

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) and scripts (resource) components.

What problem does it solve?

This Skill provides strategies to ensure TanStack Devtools are either correctly excluded from production bundles or intentionally included and managed for debugging deployed applications.

Core Features & Use Cases

  • Production Stripping: Automatically removes devtools from production builds using Vite plugins.
  • Conditional Imports: Enables manual exclusion of devtools in non-Vite projects via dynamic imports.
  • NoOp Variants: Offers tree-shakable, no-operation plugin alternatives for libraries.
  • Use Case: Ensure your production application remains lean and performant by excluding debugging tools, while still allowing for their inclusion in staging or specific debugging sessions.

Quick Start

Configure your Vite build to automatically remove devtools from production bundles.

Frequently Asked Questions about devtools-production

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I exclude devtools from a production build?

To exclude devtools from a production build, use a Vite plugin to automatically strip TanStack Devtools during the bundling process. This ensures your deployed application remains lean and performant by removing debugging tools from the final output.

Can I use conditional imports to remove devtools in non-Vite projects?

Yes, you can use conditional imports to manually exclude devtools in non-Vite projects. By leveraging dynamic imports, you ensure that devtools are only loaded when needed for staging or specific debugging sessions rather than in production environments.

What are NoOp plugin variants for tree shaking?

NoOp plugin variants are tree-shakable, no-operation alternatives designed for libraries. They allow bundlers to safely remove devtools dependencies during production builds, ensuring that unused debugging code does not inflate your final bundle size.

Does TanStack Devtools work with Vite for build stripping?

Yes, TanStack Devtools integrates with Vite for build-time stripping. Configuring your Vite build process automatically removes the devtools from production bundles, managing dependency separation between development and production environments effectively.

When should I intentionally include devtools in a production build?

You should intentionally include devtools in a production build when you need to debug deployed applications or during staging sessions. This Skill manages conditional inclusion so you can safely inject debugging tools without impacting standard production performance.