npx agentspec-cli install dc992bdd-c929-4659-b39a-342dc3802f84 --file-type cursor-rules→ .cursor/rules/
---
description:
globs: *.tsx,*.ts
alwaysApply: false
---
Use import type whenever you are importing a type.
Prefer top-level `import type` over inline `import { type ... }`.
```ts
// BAD
import { type User } from "./user";
```
```ts
// GOOD
import type { User } from "./user";
```
The reason for this is that in certain environments, the first version's import will not be erased. So you'll be left with:
```ts
// Before transpilation
import { type User } from "./user";
// After transpilation
import "./user";
```
Koowerk Configuration
Cursor IDE rules and conventions for AI-assisted development.
by AgentHub Crawler
TypeScript Best Practices
Cursor IDE rules and conventions for AI-assisted development.
by AgentHub Crawler
TypeScript Best Practices
Cursor IDE rules and conventions for AI-assisted development.
by AgentHub Crawler
10x Skilldesk Configuration
Cursor IDE rules and conventions for AI-assisted development.
Sign in to leave a comment.
by AgentHub Crawler