소스 정보
- 저장소
- saleor/apps
- 최근 소스 활동
- 2026년 1월 27일 13:25
- 감지된 SKILL.md 언어
- 영어
- 스타
- 162
- 포크
- 407
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/saleor/apps --skill add-environment-variable명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
SKILL.md 표시 중
| name | Add Environment Variable |
| description | Use when adding a new environment variable to an app. |
When adding a new environment variable to an app, follow these steps:
Find the env.ts or env.mjs file in the app that uses @t3-oss/env-nextjs. Common locations:
apps/<app-name>/src/env.tsapps/<app-name>/src/lib/env.tsThe createEnv function has three sections:
client: For variables prefixed with NEXT_PUBLIC_ (exposed to browser)server: For server-only variables (secrets, API keys, configuration)shared: For variables used in both client and server (like NODE_ENV)Use appropriate Zod schemas with validation:
// Required string
MY_VAR: z.string(),
// Optional string
MY_VAR: z.string().optional(),
// String with default value (preferred over defaults elsewhere in code)
MY_VAR: z.string().optional().default("default-value"),
// Number (use z.coerce for env vars)
MY_VAR: z.coerce.number().optional().default(5000),
// Enum
MY_VAR: z.enum(["option1", "option2"]).optional().default("option1"),
// Boolean (use the booleanSchema helper already defined in the file)
MY_VAR: booleanSchema.optional().default("false"),
// Positive number with constraints
MY_VAR: z.coerce.number().positive().optional().default(14),
// Comma-separated list transformed to array
MY_VAR: z
.string()
.optional()
.transform((s) => {
if (!s) return [];
return s.split(",").map((item) => item.trim());
}),
Add a JSDoc-style comment above the variable explaining its purpose:
server: {
// Timeout in milliseconds for Algolia API requests
ALGOLIA_TIMEOUT_MS: z.coerce.number().optional().default(5000),
// Number of items to process in a single batch during Strapi sync
STRAPI_BATCH_SIZE: z.coerce.number().optional().default(50),
}
Every variable must also be added to the runtimeEnv object:
runtimeEnv: {
// ... existing vars
MY_VAR: process.env.MY_VAR,
}
Always define default values in the env.ts file, not in the consuming code.
Bad:
// In env.ts
MY_TIMEOUT: z.coerce.number().optional(),
// In some-service.ts
const timeout = env.MY_TIMEOUT ?? 5000; // DON'T DO THIS
Good:
// In env.ts
// Timeout for external API calls in milliseconds
MY_TIMEOUT: z.coerce.number().optional().default(5000),
// In some-service.ts
const timeout = env.MY_TIMEOUT; // Already has the default
If the app has a .env.example file, add the new variable there with a placeholder or example value.
Adding MY_SERVICE_TIMEOUT_MS to the CMS app:
// In apps/cms/src/env.ts
export const env = createEnv({
server: {
// ... existing vars
// Timeout in milliseconds for My Service API calls
MY_SERVICE_TIMEOUT_MS: z.coerce.number().optional().default(10_000),
},
runtimeEnv: {
// ... existing vars
MY_SERVICE_TIMEOUT_MS: process.env.MY_SERVICE_TIMEOUT_MS,
},
});
Usage in code:
import { env } from "@/env";
const client = new MyServiceClient({
timeout: env.MY_SERVICE_TIMEOUT_MS,
});
Styling and layout guide for Saleor Apps using modern macaw-ui and @saleor/apps-ui-next. Use when creating, refactoring, or modifying React components in apps or packages/ui-next — especially layout, spacing, colors, borders, setup checklists, or settings cards. Triggers on component creation, UI refactors, and style-related tasks in the apps monorepo.
Scaffold a new shared package in the saleor-apps monorepo under ./packages/. Use when asked to "create a package", "add a new package", "scaffold a package", "new shared library", or any task that involves creating a new reusable package in the saleor-apps monorepo. Handles all boilerplate - package.json, tsconfig, eslint, vitest, turbo, lint-staged configs, and src/index.ts.
SOC 직업 분류 기준