feat: 프로젝트 초기 설정 완료 - Vite + React + TypeScript, TailwindCSS + ShadCN UI, Zustand, 기본 타입 및 컴포넌트 구현
This commit is contained in:
23
.cursor/mcp.json
Normal file
23
.cursor/mcp.json
Normal file
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"mcpServers": {
|
||||
"task-master-ai": {
|
||||
"command": "npx",
|
||||
"args": [
|
||||
"-y",
|
||||
"--package=task-master-ai",
|
||||
"task-master-ai"
|
||||
],
|
||||
"env": {
|
||||
"ANTHROPIC_API_KEY": "ANTHROPIC_API_KEY_HERE",
|
||||
"PERPLEXITY_API_KEY": "PERPLEXITY_API_KEY_HERE",
|
||||
"OPENAI_API_KEY": "OPENAI_API_KEY_HERE",
|
||||
"GOOGLE_API_KEY": "GOOGLE_API_KEY_HERE",
|
||||
"XAI_API_KEY": "XAI_API_KEY_HERE",
|
||||
"OPENROUTER_API_KEY": "OPENROUTER_API_KEY_HERE",
|
||||
"MISTRAL_API_KEY": "MISTRAL_API_KEY_HERE",
|
||||
"AZURE_OPENAI_API_KEY": "AZURE_OPENAI_API_KEY_HERE",
|
||||
"OLLAMA_API_KEY": "OLLAMA_API_KEY_HERE"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
53
.cursor/rules/cursor_rules.mdc
Normal file
53
.cursor/rules/cursor_rules.mdc
Normal file
@@ -0,0 +1,53 @@
|
||||
---
|
||||
description: Guidelines for creating and maintaining Cursor rules to ensure consistency and effectiveness.
|
||||
globs: .cursor/rules/*.mdc
|
||||
alwaysApply: true
|
||||
---
|
||||
|
||||
- **Required Rule Structure:**
|
||||
```markdown
|
||||
---
|
||||
description: Clear, one-line description of what the rule enforces
|
||||
globs: path/to/files/*.ext, other/path/**/*
|
||||
alwaysApply: boolean
|
||||
---
|
||||
|
||||
- **Main Points in Bold**
|
||||
- Sub-points with details
|
||||
- Examples and explanations
|
||||
```
|
||||
|
||||
- **File References:**
|
||||
- Use `[filename](mdc:path/to/file)` ([filename](mdc:filename)) to reference files
|
||||
- Example: [prisma.mdc](mdc:.cursor/rules/prisma.mdc) for rule references
|
||||
- Example: [schema.prisma](mdc:prisma/schema.prisma) for code references
|
||||
|
||||
- **Code Examples:**
|
||||
- Use language-specific code blocks
|
||||
```typescript
|
||||
// ✅ DO: Show good examples
|
||||
const goodExample = true;
|
||||
|
||||
// ❌ DON'T: Show anti-patterns
|
||||
const badExample = false;
|
||||
```
|
||||
|
||||
- **Rule Content Guidelines:**
|
||||
- Start with high-level overview
|
||||
- Include specific, actionable requirements
|
||||
- Show examples of correct implementation
|
||||
- Reference existing code when possible
|
||||
- Keep rules DRY by referencing other rules
|
||||
|
||||
- **Rule Maintenance:**
|
||||
- Update rules when new patterns emerge
|
||||
- Add examples from actual codebase
|
||||
- Remove outdated patterns
|
||||
- Cross-reference related rules
|
||||
|
||||
- **Best Practices:**
|
||||
- Use bullet points for clarity
|
||||
- Keep descriptions concise
|
||||
- Include both DO and DON'T examples
|
||||
- Reference actual code over theoretical examples
|
||||
- Use consistent formatting across rules
|
||||
72
.cursor/rules/self_improve.mdc
Normal file
72
.cursor/rules/self_improve.mdc
Normal file
@@ -0,0 +1,72 @@
|
||||
---
|
||||
description: Guidelines for continuously improving Cursor rules based on emerging code patterns and best practices.
|
||||
globs: **/*
|
||||
alwaysApply: true
|
||||
---
|
||||
|
||||
- **Rule Improvement Triggers:**
|
||||
- New code patterns not covered by existing rules
|
||||
- Repeated similar implementations across files
|
||||
- Common error patterns that could be prevented
|
||||
- New libraries or tools being used consistently
|
||||
- Emerging best practices in the codebase
|
||||
|
||||
- **Analysis Process:**
|
||||
- Compare new code with existing rules
|
||||
- Identify patterns that should be standardized
|
||||
- Look for references to external documentation
|
||||
- Check for consistent error handling patterns
|
||||
- Monitor test patterns and coverage
|
||||
|
||||
- **Rule Updates:**
|
||||
- **Add New Rules When:**
|
||||
- A new technology/pattern is used in 3+ files
|
||||
- Common bugs could be prevented by a rule
|
||||
- Code reviews repeatedly mention the same feedback
|
||||
- New security or performance patterns emerge
|
||||
|
||||
- **Modify Existing Rules When:**
|
||||
- Better examples exist in the codebase
|
||||
- Additional edge cases are discovered
|
||||
- Related rules have been updated
|
||||
- Implementation details have changed
|
||||
|
||||
- **Example Pattern Recognition:**
|
||||
```typescript
|
||||
// If you see repeated patterns like:
|
||||
const data = await prisma.user.findMany({
|
||||
select: { id: true, email: true },
|
||||
where: { status: 'ACTIVE' }
|
||||
});
|
||||
|
||||
// Consider adding to [prisma.mdc](mdc:.cursor/rules/prisma.mdc):
|
||||
// - Standard select fields
|
||||
// - Common where conditions
|
||||
// - Performance optimization patterns
|
||||
```
|
||||
|
||||
- **Rule Quality Checks:**
|
||||
- Rules should be actionable and specific
|
||||
- Examples should come from actual code
|
||||
- References should be up to date
|
||||
- Patterns should be consistently enforced
|
||||
|
||||
- **Continuous Improvement:**
|
||||
- Monitor code review comments
|
||||
- Track common development questions
|
||||
- Update rules after major refactors
|
||||
- Add links to relevant documentation
|
||||
- Cross-reference related rules
|
||||
|
||||
- **Rule Deprecation:**
|
||||
- Mark outdated patterns as deprecated
|
||||
- Remove rules that no longer apply
|
||||
- Update references to deprecated rules
|
||||
- Document migration paths for old patterns
|
||||
|
||||
- **Documentation Updates:**
|
||||
- Keep examples synchronized with code
|
||||
- Update references to external docs
|
||||
- Maintain links between related rules
|
||||
- Document breaking changes
|
||||
Follow [cursor_rules.mdc](mdc:.cursor/rules/cursor_rules.mdc) for proper rule formatting and structure.
|
||||
92
.cursor/rules/typescript.mdc
Normal file
92
.cursor/rules/typescript.mdc
Normal file
@@ -0,0 +1,92 @@
|
||||
---
|
||||
description:
|
||||
globs:
|
||||
alwaysApply: true
|
||||
---
|
||||
You are an expert Chrome extension developer, proficient in JavaScript/TypeScript, browser extension APIs, and web development.
|
||||
|
||||
Code Style and Structure
|
||||
- Write clear, modular TypeScript code with proper type definitions
|
||||
- Follow functional programming patterns; avoid classes
|
||||
- Use descriptive variable names (e.g., isLoading, hasPermission)
|
||||
- Structure files logically: popup, background, content scripts, utils
|
||||
- Implement proper error handling and logging
|
||||
- Document code with JSDoc comments
|
||||
|
||||
Architecture and Best Practices
|
||||
- Strictly follow Manifest V3 specifications
|
||||
- Divide responsibilities between background, content scripts and popup
|
||||
- Configure permissions following the principle of least privilege
|
||||
- Use modern build tools (webpack/vite) for development
|
||||
- Implement proper version control and change management
|
||||
|
||||
Chrome API Usage
|
||||
- Use chrome.* APIs correctly (storage, tabs, runtime, etc.)
|
||||
- Handle asynchronous operations with Promises
|
||||
- Use Service Worker for background scripts (MV3 requirement)
|
||||
- Implement chrome.alarms for scheduled tasks
|
||||
- Use chrome.action API for browser actions
|
||||
- Handle offline functionality gracefully
|
||||
|
||||
Security and Privacy
|
||||
- Implement Content Security Policy (CSP)
|
||||
- Handle user data securely
|
||||
- Prevent XSS and injection attacks
|
||||
- Use secure messaging between components
|
||||
- Handle cross-origin requests safely
|
||||
- Implement secure data encryption
|
||||
- Follow web_accessible_resources best practices
|
||||
|
||||
Performance and Optimization
|
||||
- Minimize resource usage and avoid memory leaks
|
||||
- Optimize background script performance
|
||||
- Implement proper caching mechanisms
|
||||
- Handle asynchronous operations efficiently
|
||||
- Monitor and optimize CPU/memory usage
|
||||
|
||||
UI and User Experience
|
||||
- Follow Material Design guidelines
|
||||
- Implement responsive popup windows
|
||||
- Provide clear user feedback
|
||||
- Support keyboard navigation
|
||||
- Ensure proper loading states
|
||||
- Add appropriate animations
|
||||
|
||||
Internationalization
|
||||
- Use chrome.i18n API for translations
|
||||
- Follow _locales structure
|
||||
- Support RTL languages
|
||||
- Handle regional formats
|
||||
|
||||
Accessibility
|
||||
- Implement ARIA labels
|
||||
- Ensure sufficient color contrast
|
||||
- Support screen readers
|
||||
- Add keyboard shortcuts
|
||||
|
||||
Testing and Debugging
|
||||
- Use Chrome DevTools effectively
|
||||
- Write unit and integration tests
|
||||
- Test cross-browser compatibility
|
||||
- Monitor performance metrics
|
||||
- Handle error scenarios
|
||||
|
||||
Publishing and Maintenance
|
||||
- Prepare store listings and screenshots
|
||||
- Write clear privacy policies
|
||||
- Implement update mechanisms
|
||||
- Handle user feedback
|
||||
- Maintain documentation
|
||||
|
||||
Follow Official Documentation
|
||||
- Refer to Chrome Extension documentation
|
||||
- Stay updated with Manifest V3 changes
|
||||
- Follow Chrome Web Store guidelines
|
||||
- Monitor Chrome platform updates
|
||||
|
||||
Output Expectations
|
||||
- Provide clear, working code examples
|
||||
- Include necessary error handling
|
||||
- Follow security best practices
|
||||
- Ensure cross-browser compatibility
|
||||
- Write maintainable and scalable code
|
||||
Reference in New Issue
Block a user