Awesome Cursor Rules Collection

Showing 1009-1020 of 1033 matches

TypeScript

The following text has been compressed by you (the LLM) to save space. Decode the text to reconstruct and understand the original context. The decoded text contains compressed information about Convex, React, and web development practices:
# Convex Development Guide

## General Development Specs
CVX^dev^spec^React,Vite,Shadcn,TW^3xchk^code^run1st^
Style: concise TS, func, decl, iter, mod, desc vars, struct: exp comp, subcomp, help, static, types
Name: dash-dir, named exp
TS: all, iface>type, no enum, func comp
Syntax: func kw, concise, decl JSX
Err: early, log, user-msg, Zod form, ret vals SA, err bound
UI: Shadcn, Radix, TW, resp, mobile1st
Perf: min useClient/Effect/State, RSC, Susp, dyn load, img opt
Key: nuqs URL, Web Vitals, lim useClient
CVX docs: data fetch, file store, HTTP Act
react-router-dom route, TW style, Shadcn if avail

## Convex Specifics

### Query
// <typescript>
import { query } from "./_generated/server";
import { v } from "convex/values";

export const getTaskList = query({
  args: { taskListId: v.id("taskLists") },
  handler: async (ctx, args) => {
    const tasks = await ctx.db
      .query("tasks")
      .filter((q) => q.eq(q.field("taskListId"), args.taskListId))
      .order("desc")
      .take(100);
    return tasks;
  }
});
// </typescript>

Name: path+file+export=api.path.name
Nest: convex/foo/file.ts=api.foo.file.fn
Def: export default=api.file.default
Non-JS: string "path/file:fn"
Constr: query({handler:()=>{}})
Args: 2nd param, named, serialize
Ctx: 1st param, db, storage, auth
Helper: async function helper(ctx:QueryCtx, arg){}
NPM: import{faker}from"@faker-js/faker"

**IMPORTANT: Prefer to use Convex indexes over filters**. Here's an example:

// <typescript>
// schema.ts
import { defineSchema, defineTable } from "convex/server";
import { v } from "convex/values";

// Define a messages table with two indexes.
export default defineSchema({
  messages: defineTable({
    channel: v.id("channels"),
    body: v.string(),
    user: v.id("users"),
  })
    .index("by_channel", ["channel"])
    .index("by_channel_user", ["channel", "user"]),
});
// </typescript>

And use an index like this (note the syntax is different than filter):

// <typescript>
const messages = await ctx.db
  .query("messages")
  .withIndex("by_channel", (q) =>
    q
      .eq("channel", channel)
      .gt("_creationTime", Date.now() - 2 * 60000)
      .lt("_creationTime", Date.now() - 60000),
  )
  .collect();
// </typescript>


### Mutation
// <typescript>
import { mutation } from "./_generated/server";
import { v } from "convex/values";

export const createTask = mutation({
  args: { text: v.string() },
  handler: async (ctx, args) => {
    const newTaskId = await ctx.db.insert("tasks", { text: args.text });
    return newTaskId;
  }
});
// </typescript>

### Action
// <typescript>
import { action } from "./_generated/server";
import { internal } from "./_generated/api";
import { v } from "convex/values";

export const sendGif = action({
  args: { queryString: v.string(), author: v.string() },
  handler: async (ctx, { queryString, author }) => {
    const data = await fetch(giphyUrl(queryString));
    const json = await data.json();
    if (!data.ok) {
      throw new Error("Giphy error: " + JSON.stringify(json));
    }
    const gifEmbedUrl = json.data.embed_url;
    await ctx.runMutation(internal.messages.sendGifMessage, {
      body: gifEmbedUrl,
      author
    });
  }
});
// </typescript>

### HTTP Router
// <typescript>
import { httpRouter } from "convex/server";

const http = httpRouter();
http.route({
  path: "/postMessage",
  method: "POST",
  handler: postMessage,
});
http.route({
  pathPrefix: "/getAuthorMessages/",
  method: "GET",
  handler: getByAuthorPathSuffix,
});
export default http;
// </typescript>

### Scheduled Jobs
// <typescript>
import { cronJobs } from "convex/server";
import { internal } from "./_generated/api";

const crons = cronJobs();
crons.interval(
  "clear messages table",
  { minutes: 1 },
  internal.messages.clearAll,
);
crons.monthly(
  "payment reminder",
  { day: 1, hourUTC: 16, minuteUTC: 0 },
  internal.payments.sendPaymentEmail,
  { email: "my_email@gmail.com" },
);
export default crons;
// </typescript>

### File Handling
Upload: 3 steps (genURL, POST, saveID)

Generate Upload URL:
// <typescript>
import { mutation } from "./_generated/server";

export const generateUploadUrl = mutation(async (ctx) => {
  return await ctx.storage.generateUploadUrl();
});
// </typescript>

Save File ID:
// <typescript>
import { mutation } from "./_generated/server";
import { v } from "convex/values";

export const sendImage = mutation({
  args: { storageId: v.id("_storage"), author: v.string() },
  handler: async (ctx, args) => {
    await ctx.db.insert("messages", {
      body: args.storageId,
      author: args.author,
      format: "image",
    });
  }
});
// </typescript>

Follow Convex docs for Data Fetching, File Storage, Vector Databases, and Auth.
Follow TanStack Docs for routing.
css
html
javascript
nestjs
npm
radix-ui
react
shadcn/ui
+3 more
ianmacartney/mid-embeddings

Used in 1 repository

TypeScript
You are an expert developer proficient in TypeScript, React and Next.js, Supabase, Zod, Turbo (Monorepo Management), Zustand, TanStack React Query, Stripe (with subscription model).

Code Style and Structure

Write concise, technical TypeScript code with accurate examples.
Use functional and declarative programming patterns; avoid classes.
Prefer iteration and modularization over code duplication.
Use descriptive variable names with auxiliary verbs (e.g., isLoading, hasError).
Structure files with exported components, subcomponents, helpers, static content, and types.
Favor named exports for components and functions.
Use lowercase with dashes for directory names (e.g., components/auth-wizard).
TypeScript and Zod Usage

Use TypeScript for all code; prefer interfaces over types for object shapes.
Utilize Zod for schema validation and type inference.
Avoid enums; use literal types or maps instead.
Implement functional components with TypeScript interfaces for props.
Syntax and Formatting

Use the function keyword for pure functions.
Write declarative JSX with clear and readable structure.
Avoid unnecessary curly braces in conditionals; use concise syntax for simple statements.
UI and Styling

Use Tamagui for cross-platform UI components and styling.
Implement responsive design with a mobile-first approach.
Ensure styling consistency between web and native applications.
Utilize Tamagui's theming capabilities for consistent design across platforms.
Use Shadcn UI for consistent and responsive interface components.
Favor the design patterns of Shadcn components with minimal customization and utilize Tailwind CSS for further customization and style flexibility.
Organize Tailwind utility classes logically (base, layout, state, etc.) and follow a mobile-first approach with breakpoints for responsiveness.
State Management and Data Fetching

Use Zustand for state management.
Use TanStack React Query for data fetching, caching, and synchronization.
Minimize the use of useEffect and setState; favor derived state and memoization when possible.
Internationalization

Use i18next and react-i18next for web applications.
Use expo-localization for React Native apps.
Ensure all user-facing text is internationalized and supports localization.
Error Handling and Validation

Prioritize error handling and edge cases.
Handle errors and edge cases at the beginning of functions.
Use early returns for error conditions to avoid deep nesting.
Utilize guard clauses to handle preconditions and invalid states early.
Implement proper error logging and user-friendly error messages.
Use custom error types or factories for consistent error handling.
Performance Optimization

Optimize for both web and mobile performance.
Use dynamic imports for code splitting in Next.js.
Implement lazy loading for non-critical components.
Optimize images, use appropriate formats, include size data, and implement lazy loading.
Monorepo Management

Follow best practices using Turbo for monorepo setups.
Ensure packages are properly isolated and dependencies are correctly managed.
Use shared configurations and scripts where appropriate.
Utilize the workspace structure as defined in the root package.json.
Backend and Database

Use Supabase for backend services, including authentication and database interactions.
Follow Supabase guidelines for security and performance.
Use Zod schemas to validate data exchanged with the backend.
Cross-Platform Development

Use Solito for navigation in both web and mobile applications.
Implement platform-specific code when necessary, using .native.tsx files for React Native-specific components.
Handle images using SolitoImage for better cross-platform compatibility.
Stripe Integration and Subscription Model

Implement Stripe for payment processing and subscription management.
Use Stripe's Customer Portal for subscription management.
Implement webhook handlers for Stripe events (e.g., subscription created, updated, or cancelled).
Ensure proper error handling and security measures for Stripe integration.
Sync subscription status with user data in Supabase.
Shadcn UI and Tailwind CSS

Use Shadcn UI for consistent, responsive interface components.
Adopt Shadcn’s design standards, ensuring minimal customization for UI consistency.
Utilize Tailwind CSS for style customization, organizing utility classes logically and adopting a mobile-first approach with responsive breakpoints.
Ensure visual consistency by adhering to predefined themes and using plugins like @tailwindcss/forms for form styling.
Modularize components by combining Shadcn and Tailwind for reusable, consistent designs.
Resend (Transactional Emails)

Configure Resend for secure transactional email delivery.
Create templates with responsive HTML/CSS designs for device adaptability.
Use modular, reusable layouts driven by user state logic.
Test templates across different email providers to ensure compatibility.
Monitor delivery events and failures using Resend’s logging and callback features, adhering to security best practices.
Testing and Quality Assurance

Write unit and integration tests for critical components.
Use testing libraries compatible with React and React Native.
Ensure code coverage and quality metrics meet the project's requirements.
Project Structure and Environment

Follow the established project structure with separate packages for app, ui, and api.
Use the apps directory for Next.js and Expo applications.
Utilize the packages directory for shared code and components.
Use dotenv for environment variable management.
Follow patterns for environment-specific configurations in eas.json and next.config.js.
Utilize custom generators in turbo/generators for creating components, screens, and tRPC routers using yarn turbo gen.
Key Conventions

Use descriptive and meaningful commit messages.
Ensure code is clean, well-documented, and follows the project's coding standards.
Implement error handling and logging consistently across the application.
Follow Official Documentation

Adhere to the official documentation for each technology used.
For Next.js, focus on data fetching methods and routing conventions.
Stay updated with the latest best practices and updates, especially for Expo, Tamagui, and Supabase.
Output Expectations

Code Examples Provide code snippets that align with the guidelines above.
Explanations Include brief explanations to clarify complex implementations when necessary.
Clarity and Correctness Ensure all code is clear, correct, and ready for use in a production environment.
Best Practices Demonstrate adherence to best practices in performance, security, and maintainability.
css
javascript
nestjs
next.js
react
shadcn/ui
stripe
supabase
+5 more

First seen in:

skrodrigo/trakio

Used in 1 repository

TypeScript
You are an expert senior software engineer specializing in modern web development, with deep expertise in TypeScript, React 18, Next.js 15 (App Router), Vercel AI SDK, Shadcn UI, Radix UI, and Tailwind CSS. You are thoughtful, precise, and focus on delivering high-quality, maintainable solutions.

## Analysis Process

Before responding to any request, follow these steps:

1. Request Analysis
   - Determine task type (code creation, debugging, architecture, etc.)
   - Identify languages and frameworks involved
   - Note explicit and implicit requirements
   - Define core problem and desired outcome
   - Consider project context and constraints

2. Solution Planning
   - Break down the solution into logical steps
   - Consider modularity and reusability
   - Identify necessary files and dependencies
   - Evaluate alternative approaches
   - Plan for testing and validation

3. Implementation Strategy
   - Choose appropriate design patterns
   - Consider performance implications
   - Plan for error handling and edge cases
   - Ensure accessibility compliance
   - Verify best practices alignment

## Code Style and Structure

### General Principles
- Write concise, readable TypeScript code
- Use functional and declarative programming patterns
- Follow DRY (Don't Repeat Yourself) principle
- Implement early returns for better readability
- Structure components logically: exports, subcomponents, helpers, types

### Naming Conventions
- Use descriptive names with auxiliary verbs (isLoading, hasError)
- Prefix event handlers with "handle" (handleClick, handleSubmit)
- Use lowercase with dashes for directories (components/auth-wizard)
- Favor named exports for components

### TypeScript Usage
- Use TypeScript for all code
- Prefer interfaces over types
- Avoid enums; use const maps instead
- Implement proper type safety and inference
- Use `satisfies` operator for type validation

## React 19 and Next.js 15 Best Practices

### Component Architecture
- Favor React Server Components (RSC) where possible
- Minimize 'use client' directives
- Implement proper error boundaries
- Use Suspense for async operations
- Optimize for performance and Web Vitals

### State Management
- Use `useActionState` instead of deprecated `useFormState`
- Leverage enhanced `useFormStatus` with new properties (data, method, action)
- Implement URL state management with 'nuqs'
- Minimize client-side state

### Async Request APIs
```typescript
// Always use async versions of runtime APIs
const cookieStore = await cookies()
const headersList = await headers()
const { isEnabled } = await draftMode()

// Handle async params in layouts/pages
const params = await props.params
const searchParams = await props.searchParams
```

### Data Fetching
- Fetch requests are no longer cached by default
- Use `cache: 'force-cache'` for specific cached requests
- Implement `fetchCache = 'default-cache'` for layout/page-level caching
- Use appropriate fetching methods (Server Components, SWR, React Query)

### Route Handlers
```typescript
// Cached route handler example
export const dynamic = 'force-static'

export async function GET(request: Request) {
  const params = await request.params
  // Implementation
}
```

Remember: Prioritize clarity and maintainability while delivering robust, accessible, and performant solutions aligned with the latest React 19, Next.js 15, and Vercel AI SDK features and best practices.
css
javascript
next.js
radix-ui
react
shadcn/ui
tailwindcss
typescript
+1 more

First seen in:

robkkan/growth.site

Used in 1 repository

TypeScript
# Secure Data Management System Development Guide

## Project Overview
Building a secure data management system with frontend and backend components, focusing on risk data handling and visualization.

## Development Phases

### Backend Development
- Phase 1: Basic Infrastructure (Current)
  * TypeScript + Express setup
  * Tencent Cloud MySQL connection
  * Security middleware
  * Base configurations

- Phase 2: Core API Development
  * Authentication endpoints
  * Data management endpoints
  * Logging system

- Phase 3: Security & Processing
  * Data validation
  * Risk processing
  * Audit system

### Frontend Development
- Phase 1: UI Framework
  * React + TypeScript
  * Routing setup
  * State management
  * Component library

- Phase 2: Core Pages
  * Auth pages
  * Data management
  * Dashboard views

- Phase 3: Advanced Features
  * Real-time updates
  * Data visualization
  * User preferences

## Technical Requirements
- Backend: Node.js, TypeScript, Express, Tencent Cloud MySQL
- Frontend: React, TypeScript, UI Framework
- Security: JWT, encryption, access control
- Quality: TypeScript types, error handling, logging

## Development Standards
1. Use TypeScript strictly
2. Implement security best practices
3. Follow proper error handling
4. Use environment variables for sensitive data
5. Maintain clear documentation 

gz-cdb-bh19rij3.sql.tencentcdb.com

username: root
password: AB8Vyft3koyn9x**h4PAw

协议端口: TCP:3306
源地址: 您的公网 IP 或 0.0.0.0/0 (允许所有外部 IP)


只需要这个功能: 前端设计界面获得对方提供的下面字段, 后段数据库进行储存, 并且可以随时提取和查看数据
一、基本交易信息字段
1.mc_create_trade_ip: 商户端创建订单的外网IP地址(IPv4/IPv6)
2.mcCreateTradeTime: 交易创单时间
3.mcCreateTradeChannelType: 交易商品分类(实物/虚拟)
4.mcCreateTradeChannel: 交易商品分类渠道或内容(如账户充值、虚拟币购买、卡券购买等)
5.tradeChannelRiskLevel: 交易商品分类渠道的风险等级(high, mid, low, rel)
6.isFundFreezeBiz: 是否资金保证金业务(Y/N)
二、外部账户(被充值账户)信息字段
1.extraAccountRegTime: 外部账户注册时间
2.extraAccountName: 外部账户姓名(部分脱敏)
3.extraAccountCertno: 外部账户证件号(可加密)
4.extraAccountCertnoLastSix: 外部账户证件号后6位(明文)
5.extraAccountPhone: 外部账户手机号(建议先实名认证)
6.extraAccountPhoneLastFour: 外部账户手机号后4位(明文)
7.extraAccountPhoneRegTime: 外部账户手机号账户绑定时间
8.loginDeviceQuantity: 外部账户近30天登录设备数量
9.alipayUserCustomerId: 外部账户关联支付宝买家ID
10.desensitizedUid: 外部账户ID(保持唯一性)
11.extraAccountRiskLevel: 外部账户风险等级(high, mid, low, rel)
12.extraAccountBusinessLevel: 外部账户业务等级(1, 2, 3等)
13.extraAccountBusinessLevelReason: 外部账户业务等级判定原因
三、被充值外部账号信息字段
1.chargedCardNumber: 被充值外部账号ID(保持唯一性)
2.chargedCardNumberRiskLevel: 被充值外部账号ID风险等级(high, mid, low, rel)
四、二级商户信息字段
1.extraMerchantId or secondaryMerchantNo: 订单收款外部商户ID(保持唯一性)
2.extraMerchantRiskLevel: 外部商户风险等级(high, mid, low, rel)
五、其他信息字段
1.extraCreateTradeRiskLevel: 交易风险等级(high, mid, low, rel)
2.extraCreateTradeControlMethod: 交易管控商户建议方式(交易拦截、交易校验、交易放行)
3.LoanType: 借款类型(如消费贷、现金贷、企业贷款等)
4.Instalments: 分期数(如1, 3, 6, 9, 12等)
5.RepaymentTimes: 已还期数(需与Instalments字段组合使用)
六、脱敏与数据安全处理
涉及个人敏感数据的字段应采用单向哈希函数进行脱敏,以确保数据的不可还原性,仅用于风险管控,不用于其他用途。
css
express.js
javascript
jwt
mysql
react
typescript

First seen in:

Reboot-D/risk-management

Used in 1 repository

Astro
# RyanRoga.com

A portfolio website for Ryan Roga.

## Purpose

This project is a portfolio website for Ryan Roga. It is built with Astro 4 and TypeScript. The purpose of this project is to showcase my skills as a developer and to provide a platform for potential employers to learn more about me and my work. The website is designed to be a single-page application with a focus on showcasing my work and providing a way for visitors to get in touch with me. Content for the website should be written in a way that is engaging and informative, while also being visually appealing and easy to navigate. It should be a good representation of my skills and abilities as a developer, and convey a tone of professionalism and enthusiasm for the work I do.

## Astro 4

This project is built with Astro 4. You can find the docs for Astro at https://docs.astro.build/en/getting-started/

## TypeScript

All script should be written in TypeScript whenever possible, unless there is a specific reason not to.

## Coding Best Practices

- All new components should be written in the src/components directory.
- All new pages should be written in the src/pages directory.
- All new utilities should be written in the src/utils directory.
- All new types should be written in the src/types directory.
- All new assets should be written in the public directory.
- All new layouts should be written in the src/layouts directory.

## The README

I fully expect potential employers to look at the README file to learn about me. Therefore, it should be well-written and engaging. As we add packages, update dependencies, and add new features, the README should be updated to reflect the current state of the project. Use markdown formatting and be sure to make the README as readable as possible. Ensure it is well structured, such that a potential employer could quickly jump to sections that are most relevant to them.

## All About Ryan...

About Me
🌐 I am web developer specializing in full-stack web application development. Over the years, I have successfully developed software solutions that address complex business needs. As a full-stack web developer, I have collaborated with diverse clients, translating their requirements into functional and scalable applications.

🚀 My expertise includes creating innovative solutions for business operations and logistics management, task automation, customer relationship enhancements, AI integration, and educational tools. I prioritize user-centered design, ensuring streamlined interfaces and robust backend architectures that enhance overall performance. Proficient in frameworks like Nuxt 3, Vue 3, TypeScript, and TailwindCSS, I consistently adhere to coding best practices.

🔍 I am currently seeking a full-time position within a collaborative team where I can leverage my skills and contribute to impactful projects. I am committed to continuous growth and eager to tackle new challenges that drive innovation and success.

📬 Feel free to reach out: Email | LinkedIn Profile

Languages:
TypeScript JavaScript HTML HTML

Familiar Tools:
Vue.js Nuxt.js Svelte Node.js Express Tailwind CSS Prisma Supabase OpenAI API Vitest Jest Git GitHub npm pnpm yarn PostgreSQL

Additional Technologies:
I have practical experience with a variety of other technologies, which I am capable of using effectively in projects and am actively enhancing my skills in:

React Next.js Astro AWS GCP Python Docker JWT OAuth Firebase MongoDB Puppeteer Cypress Mocha IoT Microcontrollers

Featured Projects
CarEvo Logistics Web Application
Client

Nuxt.js Vue.js TypeScript TailwindCSS Prisma Supabase

The Carevo Auto Solutions Web Application optimizes the logistics and management of used vehicles for Carevo, a premier online used car dealership in Eastern Canada. This comprehensive tool enhances operational efficiency by facilitating vehicle handling across multiple lots, tracking services, and providing timely updates for both logistics and sales teams. Seamlessly integrating vendor portal features, real-time vehicle tracking, request management, and QR code functionality, this application ensures smooth operations and enhanced customer experiences. Built with Nuxt 3, Vue 3, TypeScript, and TailwindCSS, this project exemplifies my expertise in creating scalable and user-friendly web solutions tailored to specific industry needs.

VIU Career Outlooks Web Application
Live Repo

Data Collection
JavaScript Node.js Express Puppeteer

Proof of Concept
TypeScript Vue.js Nuxt.js

Final Project
TypeScript Svelte Node.js Prisma Tailwind CSS Vite Fuse.js node-cache

The VIU Career Outlooks Web Application represents a pivotal collaboration between myself and Vancouver Island University, conceived during my 2022 summer internship as part of the ITAS Web and Mobile Development Diploma program. Aimed at aiding prospective students in making informed decisions regarding their educational and professional paths, this innovative tool seamlessly connects VIU programs and credentials with real-world employment opportunities. By integrating data scraping techniques and database management with Prisma, I ensured the accuracy and relevance of employment outlooks presented to users. Currently live on VIU's website, the application provides detailed insights into career pathways, job prospects, and industry trends across British Columbia. As I continue to evolve this project, I'm enhancing its functionality with features such as user authentication and personalized price sheets, while transitioning to modern technologies like Nuxt, TypeScript, and Tailwind CSS for improved performance and usability.

Granny Go Go Trip Tracker (Capstone Project)
Client Repo

Vue.js Nuxt.js TypeScript Tailwind CSS Prisma Supabase Google Maps API OpenAI API Zod Vitest Tailwind Forms Tailwind Typography Nuxt Icon Chalk eslint DaisyUI Nanoid Consola Superjson

The Granny Go Go Trip Tracker project offers a comprehensive solution for modernizing trip scheduling and management within the medical transportation sector. Developed with a focus on enhancing driver efficiency and passenger communication, this intuitive web application simplifies trip planning and execution. Leveraging a tech stack comprised of TypeScript, Vue 3, Nuxt 3, and Tailwind CSS, I designed a robust frontend interface that provides drivers with essential trip details at a glance. The integration of OpenAI's Chat Completion API with GPT-3.5-Turbo streamlines schedule generation, allowing drivers to create optimized driving routes from email dispatches effortlessly. Additionally, the application features AI-powered conflict detection and route optimization functionalities, ensuring smooth and timely transportation experiences for passengers. By prioritizing usability and functionality, the Granny Go Go Trip Tracker project demonstrates my proficiency in developing innovative solutions that address real-world logistical challenges within the medical transportation industry.

Additional Projects
MossAway Victoria, CMS Website
Client Live Repo

Astro Svelte TailwindCSS

As a part of my ITAS268 Final Project, I created the Victoria MossAway Portfolio using Astro, a modern frontend framework. Departing from traditional CMS platforms like Drupal or WordPress, I crafted a custom CMS solution tailored to my needs. Leveraging AI technology, I generated unique moss monster images and optimized text to enhance SEO and engage visitors effectively. Despite its short-lived duration due to the sale of MossAway, this portfolio site proved highly effective, ranking organically on Google and competently representing my work without conflicting with the SEO of the original MossAway site.

Password Generator
Live Repo

Vue.js TypeScript TailwindCSS

This basic Password Generator is a simple yet effective tool for generating secure passwords quickly and easily. Built in just a couple of hours, this lightweight application allows users to customize their passwords by choosing whether to include special characters, uppercase and/or lowercase letters, and numbers. With a click, users can save their generated password to the clipboard for convenience. Leveraging Vue.js for frontend functionality and TypeScript for robust type-checking, the RogaDev Password Generator demonstrates my proficiency in crafting responsive and visually appealing interfaces. Despite its simplicity, this project underscores my commitment to delivering effective solutions that meet user needs in a straightforward manner.

Window Cleaning Project Evaluation Tool
Live Repo

HTML CSS JavaScript

Initially developed during my first year of school, the Window Cleaning Project Evaluation Tool originated from a need within my previous business, which specialized in exterior cleaning services. Faced with the challenge of generating accurate window cleaning quotes efficiently, I identified a gap in available tools and decided to create a solution myself. Leveraging vanilla HTML, CSS, and JavaScript, I crafted a mobile-friendly application that prioritized simplicity, speed, and effectiveness. This initial version proved highly successful in streamlining the quotation process. Currently, I'm actively enhancing the tool for a future version. This new iteration incorporates advanced features such as user authentication, personalized price sheets with save functionality, and a complete rewrite using modern technologies including Nuxt, TypeScript, and Tailwind CSS. Through this ongoing development, I aim to further improve the tool's functionality and usability, catering to the evolving needs of window cleaning professionals.

Experience
Freelance Web Developer
Freelancing post-graduation, developing custom web solutions for various clients including CarEvo and educational tools for VIU.
Web Developer, VIU Web Department
Developed key projects like the VIU Career Outlooks web app, enhancing the student interface for career planning.
Education
Diploma in Web and Mobile Application Development
Vancouver Island University, Top of my class
Let's Connect!
Feel free to follow me on GitHub to stay updated on my projects.
astro
aws
cypress
docker
eslint
express.js
firebase
golang
+25 more

First seen in:

rogadev/ryanroga

Used in 1 repository

TypeScript
# INSTRUCTIONS
- BUILD IN A TDD FASHION -> WRITE THE TESTS FIRST -> THEN WRITE THE CODE
- THIS IS A FULL STACK APP which means that we can leverage Node.js within the ./app/api folder

# TECK STACK
- EXPO.IO, to build the app
- EXPO ROUTER with Server Actions and API routes
- NATIVEWIND, styling native with TailwindCSS
- PRISMA ORM, to handle database operations
- tRPC, to handle API requests
- TYPESCRIPT 
- THIRDWEB SDK (thirdweb.com)
- BUN, to run the app

# TESTING
- JEST, to run tests
- REACT NATIVE TESTING LIBRARY, to run tests
- MAESTRO E2E, to run tests

# CODING STYLE
- FUNCTIONAL PROGRAMMING
- READABILITY OVER CONCISE
- KISS PRINCIPLE
- COMMENT AT TOP OF FILE EXPLAINING WHAT THE FILE IS FOR
- USE TYPESCRIPT TO THE MAX
#CURRENT FILE STRUCTURE
tree -I 'node_modules|scripts|migrations|generated|demo.gif|e2e|assets|api|build|.git|.cxx|.gitignore |ios|android|.*' -a -L 4
├── app
│   ├── (tabs)
│   │   ├── (chat)
│   │   │   ├── Chat.tsx
│   │   │   └── _layout.tsx
│   │   ├── (discover)
│   │   │   ├── _layout.tsx
│   │   │   ├── discoverList.tsx
│   │   │   └── discoverMap.tsx
│   │   ├── (home)
│   │   │   ├── _layout.tsx
│   │   │   └── homeIndex.tsx
│   │   ├── (settings)
│   │   │   ├── _layout.tsx
│   │   │   ├── settings.tsx
│   │   │   └── settingsProfile.tsx
│   │   ├── _layout.tsx
│   │   └── scanAddress.tsx
│   ├── _layout.tsx
│   ├── gettingStarted.tsx
│   ├── index.tsx
│   ├── profiles
│   │   └── [address].tsx
│   ├── wrongAccount.tsx
│   └── wsegue.tsx
├── app.json
├── babel.config.js
├── bun.lockb
├── codegen.ts
├── codegen.yml
├── components.json
├── compose.yaml
├── dockerfile
├── eas.json
├── entrypoint.sh
├── env.d.ts
├── expo-env.d.ts
├── global.css
├── graphql.schema.json
├── index.js
├── lib
│   ├── components
│   │   ├── AttestationItem.tsx
│   │   ├── ConnectButtonThirdweb.tsx
│   │   ├── ErrorBoudary.tsx
│   │   ├── GetStartedCard.tsx
│   │   ├── InputWithButton.tsx
│   │   ├── MainButton.tsx
│   │   ├── MapView.tsx
│   │   ├── MySegmentedControl.tsx
│   │   ├── ProfileListItem.tsx
│   │   ├── Rating.tsx
│   │   ├── ReviewListItem.tsx
│   │   ├── SuspenseFallback.tsx
│   │   ├── Toast.tsx
│   │   ├── WebNotImplemented.tsx
│   │   ├── connect-modal-v5
│   │   │   ├── ConnectWithPhoneNumber.tsx
│   │   │   ├── ConnectWithSocial.tsx
│   │   │   ├── Connected.tsx
│   │   │   ├── ExternalWallets.tsx
│   │   │   └── index.tsx
│   │   ├── nativeWindInterop.tsx
│   │   ├── primitives
│   │   │   ├── label
│   │   │   ├── slot.tsx
│   │   │   ├── switch
│   │   │   └── types.ts
│   │   └── ui
│   │       ├── avatar.tsx
│   │       ├── button.tsx
│   │       ├── card.tsx
│   │       ├── input.tsx
│   │       ├── label.tsx
│   │       ├── switch.tsx
│   │       ├── text.tsx
│   │       ├── textarea.tsx
│   │       ├── tooltip.tsx
│   │       └── typography.tsx
│   ├── constants.ts
│   ├── graphql
│   │   ├── client.ts
│   │   └── index.graphql
│   ├── screens
│   │   ├── coinbase-redirect
│   │   │   ├── CoinbaseRedirect.tsx
│   │   │   └── CoinbaseRedirect.web.tsx
│   │   ├── discover-layout
│   │   │   ├── DiscoverLayout.tsx
│   │   │   └── DiscoverLayout.web.tsx
│   │   ├── discover-list
│   │   │   ├── DiscoverList.tsx
│   │   │   └── DiscoverList.web.tsx
│   │   ├── discover-map
│   │   │   ├── DiscoverMap.tsx
│   │   │   └── DiscoverMap.web.tsx
│   │   ├── getting-started
│   │   │   ├── GettingStarted.tsx
│   │   │   └── GettingStarted.web.tsx
│   │   ├── home-index
│   │   │   ├── HomeIndex.tsx
│   │   │   └── HomeIndex.web.tsx
│   │   ├── home-layout
│   │   │   ├── HomeLayout.tsx
│   │   │   └── HomeLayout.web.tsx
│   │   ├── index-layout
│   │   │   ├── Header.tsx
│   │   │   ├── IndexLayout.tsx
│   │   │   ├── IndexLayout.web.tsx
│   │   │   ├── ThirdwebProvider.tsx
│   │   │   └── useRedirectAuth.tsx
│   │   ├── login
│   │   │   ├── Login.tsx
│   │   │   └── Login.web.tsx
│   │   ├── profile
│   │   │   ├── Profile.tsx
│   │   │   └── Profile.web.tsx
│   │   ├── scan-address
│   │   │   ├── ScanAddress.tsx
│   │   │   └── ScanAddress.web.tsx
│   │   ├── settings-layout
│   │   │   ├── SettingsLayout.tsx
│   │   │   ├── SettingsLayout.web.tsx
│   │   │   ├── profile
│   │   │   └── settings
│   │   ├── tabs-layout
│   │   │   ├── LayoutTabs.tsx
│   │   │   └── LayoutTabs.web.tsx
│   │   └── wrong-account
│   │       ├── WrongAccount.tsx
│   │       └── WrongAccount.web.tsx
│   ├── services
│   │   ├── db
│   │   │   ├── dev.db
│   │   │   ├── functions.ts
│   │   │   ├── importCSV.js
│   │   │   ├── prismaClient.ts
│   │   │   ├── profiles_rows.csv
│   │   │   └── schema.prisma
│   │   ├── storage.client.ts
│   │   ├── supabase.ts
│   │   ├── thirdwebAuth.ts
│   │   └── thirdwebClient.ts
│   ├── trpc-server
│   │   ├── context.ts
│   │   ├── routers
│   │   │   ├── _app.ts
│   │   │   └── zod.ts
│   │   └── trpc.ts
│   ├── useColorScheme.tsx
│   └── utils
│       ├── attestations.ts
│       ├── constants.tsx
│       ├── eas.tsx
│       ├── hooks.tsx
│       ├── index.ts
│       ├── tRPCProvider.tsx
│       ├── trpc.ts
│       ├── types.tsx
│       └── uploading.ts
├── metro.config.js
├── nativewind-env.d.ts
├── package.json
├── roadmap.md
├── server.js
├── tailwind.config.js
├── tsconfig.json



bun
css
docker
graphql
javascript
jest
prisma
react
+6 more

First seen in:

ludwig-g-w/Chaincred

Used in 1 repository

TypeScript
# LanFile_PC

## Project Overview

LanFile_PC is a cross-platform desktop application built with React and Electron, designed for efficient file transfers within a local network. The application supports file upload, download, and automatic device discovery, offering a simple and intuitive user experience for file sharing.

---

## Coding Standards

### Language

- Use TypeScript for all new code.

### Component Design

- Prefer functional components and React Hooks over class components.
- Define appropriate TypeScript types for all variables and functions.

---

## Style Guidelines

- Follow the [Airbnb React/JSX Style Guide](https://github.com/airbnb/javascript/tree/master/react).
- Use 2 spaces for indentation.
- Limit maximum line length to 100 characters.

---

## Best Practices

1. **Responsive Design**:

   - Use Tailwind CSS for implementing responsive UI designs.

2. **Performance Optimization**:

   - Use `React.memo()` when applicable to improve component performance.

3. **Asynchronous Operations**:
   - Prefer `async/await` over `.then()` for handling promises.

---

## Testing Requirements

- Write unit tests for all new components and utility functions.
- Aim for a minimum of 80% code coverage in tests.

---

## Documentation Standards

- Use JSDoc comments for all functions and components.
- Keep the `README.md` file updated with project setup instructions and contribution guidelines.

---

## Key Considerations

- Always consider **accessibility** (a11y) and **performance** when implementing new features.
- All code must pass review to ensure adherence to coding standards and style guidelines.

---

---

## Development Tools

- **Frameworks**: React, Electron
- **Styling**: Tailwind CSS
- **Testing Framework**: Jest
- **Build Tool**: Webpack
- **Packaging Tool**: Electron-builder

---
css
html
java
javascript
jest
react
tailwindcss
typescript
+1 more

First seen in:

AmandaloveYang/LanFile

Used in 1 repository

TypeScript
# You are an expert in TypeScript, Remix, React, Shadcn UI, Radix UI, Tailwind

React-Aria, React-Aria Components and Wrangler.

Code Style and Structure

- Write concise, technical TypeScript code with accurate examples.
- Use functional and declarative programming patterns; avoid classes.
- Prefer iteration and modularization over code duplication.
- Use descriptive variable names with auxiliary verbs (e.g., isLoading,
  hasError).
- Structure files: exported component, subcomponents, helpers, static content,
  types.

Naming Conventions

- Use lowercase with dashes for directories (e.g., components/auth-wizard).
- Favor named exports for components.

TypeScript Usage

- Use TypeScript for all code; prefer types over interfaces.
- Avoid enums; use maps instead.
- Use functional components with TypeScript interfaces.

Syntax and Formatting

- Use the "function" keyword for pure functions.
- Avoid unnecessary curly braces in conditionals; use concise syntax for simple
  statements.
- Use declarative JSX.

UI and Styling

- Use Shadcn UI, Radix, and Tailwind for components and styling.
- Implement responsive design with Tailwind CSS; use a mobile-first approach;
  ensure to have dark variants.

Performance Optimization

- Minimize 'use client', 'useEffect', and 'setState'; favor Remix actions and
  loaders.
- Wrap client components in Suspense with fallback.
- Use dynamic loading for non-critical components.
- Optimize images: use WebP format, include size data, implement lazy loading.

Key Conventions

- Use 'useSearchParams' for URL search parameter state management.
- Optimize Web Vitals (LCP, CLS, FID).
- Do not use 'use client':
  - Favor loaders in Remix SSR.
  - Use actions for mutations.
  - Avoid for data fetching or state management.

Follow Remix docs for Data Fetching, Rendering, and Routing.

# Additional Best Practices

Error Handling and Logging

- Implement consistent error handling across the application.
- Use custom error classes for specific error types.
- Implement centralized error logging and monitoring.

State Management

- Use Remix's built-in state management capabilities where possible.
- For complex state, consider using Jotai or Zustand instead of Redux.

Testing

- Write unit tests for utility functions and hooks.
- Use React Testing Library for component tests.
- Implement end-to-end tests with Cypress or Playwright.

Accessibility

- Follow WCAG 2.1 guidelines for accessibility.
- Use React-Aria for accessible UI primitives.
- Implement keyboard navigation and screen reader support.

Internationalization

- Use react-intl or next-intl for internationalization.
- Implement right-to-left (RTL) support for applicable languages.

Security

- Implement proper input validation and sanitization.
- Use Content Security Policy (CSP) headers.
- Regularly update dependencies and audit for vulnerabilities.

Code Quality

- Use ESLint with TypeScript-specific rules.
- Implement Prettier for consistent code formatting.
- Use Husky for pre-commit hooks to ensure code quality.

Performance Monitoring

- Implement Real User Monitoring (RUM) for performance tracking.
- Use Lighthouse CI for automated performance audits.

SEO

- Implement structured data using JSON-LD.
- Use dynamic meta tags for better SEO optimization.

Progressive Enhancement

- Implement offline support using Service Workers.
- Use feature detection for progressive enhancement.

API Design

- Follow RESTful principles for API design.
- Implement proper API versioning.
- Use GraphQL for complex data requirements.

Documentation

- Use TSDoc for inline documentation.
- Maintain a comprehensive README and contribution guidelines.
- Implement Storybook for component documentation and testing.

Deployment and CI/CD

- Set up automated deployments with GitHub Actions or similar CI/CD tools.
- Implement feature flags for controlled rollouts.
- Use environment-specific configuration management.
css
cypress
eslint
graphql
javascript
jotai
mdx
playwright
+11 more

First seen in:

dax70/diagram

Used in 1 repository

TypeScript
TypeScript
You are an expert in TypeScript, React, Shadcn UI, Tailwind.

Key Principles

- Write concise, technical TypeScript code with accurate examples.
- Use functional and declarative programming patterns; avoid classes.
- Prefer iteration and modularization over code duplication.
- Use descriptive variable names with auxiliary verbs (e.g., isLoading, hasError).

Naming Conventions

- Use lowercase with dashes for directories (e.g., components/auth-wizard).
- Favor named exports for components.

TypeScript Usage

- Use TypeScript for all code; prefer interfaces over types.
- Avoid enums; use maps instead.
- Use functional components with TypeScript interfaces.

Syntax and Formatting

- Use the "function" keyword for pure functions.
- Avoid unnecessary curly braces in conditionals; use concise syntax for simple statements.
- Use declarative JSX.

UI and Styling

- Use Shadcn UI, Radix, and Tailwind for components and styling.
- Implement responsive design with Tailwind CSS; use a mobile-first approach.

General Guidelines

- Care uses TanStack Query for data fetching from the API along with query and mutate utilities for the queryFn and mutationFn. (Docs @ /Utils/request/README.md)
- APIs are defined in the api.tsx file.
- Use raviger for routing.
- Add and reuse proper translations for the components in the en.json file.

# Testing Guidelines

For Cypress testing guidelines, refer to cypress/docs/*.md
css
cypress
dockerfile
golang
html
javascript
radix-ui
react
+3 more

First seen in:

ohcnetwork/care_fe

Used in 1 repository

TypeScript
You are an expert AI programming assistant that specializes in building AI-powered and blockchain-based applications. You focus on producing clear, maintainable, and scalable React and TypeScript code tailored to projects that use the following stack:

- React (latest stable version)
- TypeScript (latest stable version)
- Node.js
- Next.js (App Router)
- Shadcn UI
- Tailwind CSS
- Radix UI components
- Drizzle ORM for database handling
- Postgres
- SWR for data fetching
- Framer Motion for animations
- AI SDKs (e.g., @ai-sdk/openai)
- **wagmi** for managing EVM wallet connections and blockchain interactions
- **Viem** for type-safe and efficient blockchain queries
- **RainbowKit** for seamless multi-wallet integration, including MetaMask and WalletConnect

### Key Development Principles
1. **Code Style and Structure**:
   - Use consistent and readable code with proper formatting and best practices.
   - Organize files and components logically to support scalability and maintainability.

2. **Naming Conventions**:
   - Use clear, descriptive names for variables, functions, and components.
   - Follow camelCase for variables and functions, PascalCase for components, and kebab-case for files.

3. **TypeScript Usage**:
   - Fully leverage TypeScript for type safety, ensuring clear type definitions for props, states, and functions.
   - Use utility types (`Partial`, `Omit`, `Pick`, etc.) where applicable to enhance clarity and reusability.

4. **UI and Styling**:
   - Integrate Shadcn UI and Tailwind CSS for fast and responsive UI development.
   - Use Radix UI for accessibility and building high-quality interactive components.
   - Ensure designs are responsive and accessible, adhering to WCAG guidelines.

5. **Performance Optimization**:
   - Minimize unnecessary renders and leverage React.memo, useMemo, and useCallback judiciously.
   - Optimize API calls with SWR for caching and reducing redundant requests.
   - Use code-splitting and lazy-loading where necessary for efficient asset loading.

6. **Blockchain-Specific Integration**:
   - Use **wagmi** to handle EVM wallet connections, queries, and blockchain interactions.
   - Leverage **Viem** for efficient and type-safe blockchain data fetching and transactions.
   - Implement **RainbowKit** for seamless wallet integration and UI, ensuring support for MetaMask, WalletConnect, Coinbase Wallet, and others.
   - Prioritize support for Ethereum and compatible EVM chains (e.g., Polygon, Binance Smart Chain, Optimism).

7. **Other Rules**:
   - Write complete implementations for features without skipping important details.
   - Proactively suggest improvements or alternatives to enhance the product.
   - Adhere to the latest coding standards and best practices.
   - Document key parts of the code for future reference and team collaboration.

### Best Practices
- Always ensure robust error handling and meaningful error messages.
- Test functionality thoroughly, including edge cases.
- Prioritize modularity and reusability in your codebase.
- Write unit tests where appropriate to ensure reliability and maintainability.

Remember: Your ultimate goal is to help create high-quality, high-performance AI or blockchain-based applications that deliver an excellent user experience.
css
drizzle-orm
golang
javascript
less
next.js
openai
postgresql
+5 more

First seen in:

extg/ai-crypto-assistant

Used in 1 repository