[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6EZAX8EYD20PX2PBM33M0F9":3,"skill-same:01M6EZAX8EYD20PX2PBM33M0F9":69},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":35,"linkOnly":36,"markdownContent":37,"markdownBody":38,"frontMatter":39,"refName":40,"commitSha":41,"skillDirectory":42,"forksCount":43,"repositoryHtmlUrl":44,"repositoryHomepageUrl":45,"ownerHtmlUrl":46,"ownerBlogUrl":6,"ownerDescription":47,"updatedAt":48,"install":49,"resources":62},"01M6EZAX8EYD20PX2PBM33M0F9","nx-workspace-patterns",null,"Configure and optimize Nx monorepo workspaces. Use when setting up Nx, configuring project boundaries, optimizing build caching, or implementing affected commands.","ComeOnOliver\u002Fskillshub","ComeOnOliver","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F43215937?v=4","01M6E5JNFECJAAVFE0W7SMWWD2","Haoran Shu","01M6E5JNNDQS7AJZDYFQ8TPZCK",67,"MIT","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Faiskillstore\u002Fmarketplace\u002Fsickn33\u002Fnx-workspace-patterns\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34],"workspace","nx workspace","nx workspace patterns","patterns","nx","configure","monorepo","use","up","workspaces","build","optimize","caching","project","commands","nx monorepo","2026-11-10 10:12:30",false,"---\nname: nx-workspace-patterns\ndescription: Configure and optimize Nx monorepo workspaces. Use when setting up Nx, configuring project boundaries, optimizing build caching, or implementing affected commands.\n---\n\n# Nx Workspace Patterns\n\nProduction patterns for Nx monorepo management.\n\n## Do not use this skill when\n\n- The task is unrelated to nx workspace patterns\n- You need a different domain or tool outside this scope\n\n## Instructions\n\n- Clarify goals, constraints, and required inputs.\n- Apply relevant best practices and validate outcomes.\n- Provide actionable steps and verification.\n- If detailed examples are required, open `resources\u002Fimplementation-playbook.md`.\n\n## Use this skill when\n\n- Setting up new Nx workspaces\n- Configuring project boundaries\n- Optimizing CI with affected commands\n- Implementing remote caching\n- Managing dependencies between projects\n- Migrating to Nx\n\n## Core Concepts\n\n### 1. Nx Architecture\n\n```\nworkspace\u002F\n├── apps\u002F              # Deployable applications\n│   ├── web\u002F\n│   └── api\u002F\n├── libs\u002F              # Shared libraries\n│   ├── shared\u002F\n│   │   ├── ui\u002F\n│   │   └── utils\u002F\n│   └── feature\u002F\n│       ├── auth\u002F\n│       └── dashboard\u002F\n├── tools\u002F             # Custom executors\u002Fgenerators\n├── nx.json            # Nx configuration\n└── workspace.json     # Project configuration\n```\n\n### 2. Library Types\n\n| Type | Purpose | Example |\n|------|---------|---------|\n| **feature** | Smart components, business logic | `feature-auth` |\n| **ui** | Presentational components | `ui-buttons` |\n| **data-access** | API calls, state management | `data-access-users` |\n| **util** | Pure functions, helpers | `util-formatting` |\n| **shell** | App bootstrapping | `shell-web` |\n\n## Templates\n\n### Template 1: nx.json Configuration\n\n```json\n{\n  \"$schema\": \".\u002Fnode_modules\u002Fnx\u002Fschemas\u002Fnx-schema.json\",\n  \"npmScope\": \"myorg\",\n  \"affected\": {\n    \"defaultBase\": \"main\"\n  },\n  \"tasksRunnerOptions\": {\n    \"default\": {\n      \"runner\": \"nx\u002Ftasks-runners\u002Fdefault\",\n      \"options\": {\n        \"cacheableOperations\": [\n          \"build\",\n          \"lint\",\n          \"test\",\n          \"e2e\",\n          \"build-storybook\"\n        ],\n        \"parallel\": 3\n      }\n    }\n  },\n  \"targetDefaults\": {\n    \"build\": {\n      \"dependsOn\": [\"^build\"],\n      \"inputs\": [\"production\", \"^production\"],\n      \"cache\": true\n    },\n    \"test\": {\n      \"inputs\": [\"default\", \"^production\", \"{workspaceRoot}\u002Fjest.preset.js\"],\n      \"cache\": true\n    },\n    \"lint\": {\n      \"inputs\": [\"default\", \"{workspaceRoot}\u002F.eslintrc.json\"],\n      \"cache\": true\n    },\n    \"e2e\": {\n      \"inputs\": [\"default\", \"^production\"],\n      \"cache\": true\n    }\n  },\n  \"namedInputs\": {\n    \"default\": [\"{projectRoot}\u002F**\u002F*\", \"sharedGlobals\"],\n    \"production\": [\n      \"default\",\n      \"!{projectRoot}\u002F**\u002F?(*.)+(spec|test).[jt]s?(x)?(.snap)\",\n      \"!{projectRoot}\u002Ftsconfig.spec.json\",\n      \"!{projectRoot}\u002Fjest.config.[jt]s\",\n      \"!{projectRoot}\u002F.eslintrc.json\"\n    ],\n    \"sharedGlobals\": [\n      \"{workspaceRoot}\u002Fbabel.config.json\",\n      \"{workspaceRoot}\u002Ftsconfig.base.json\"\n    ]\n  },\n  \"generators\": {\n    \"@nx\u002Freact\": {\n      \"application\": {\n        \"style\": \"css\",\n        \"linter\": \"eslint\",\n        \"bundler\": \"webpack\"\n      },\n      \"library\": {\n        \"style\": \"css\",\n        \"linter\": \"eslint\"\n      },\n      \"component\": {\n        \"style\": \"css\"\n      }\n    }\n  }\n}\n```\n\n### Template 2: Project Configuration\n\n```json\n\u002F\u002F apps\u002Fweb\u002Fproject.json\n{\n  \"name\": \"web\",\n  \"$schema\": \"..\u002F..\u002Fnode_modules\u002Fnx\u002Fschemas\u002Fproject-schema.json\",\n  \"sourceRoot\": \"apps\u002Fweb\u002Fsrc\",\n  \"projectType\": \"application\",\n  \"tags\": [\"type:app\", \"scope:web\"],\n  \"targets\": {\n    \"build\": {\n      \"executor\": \"@nx\u002Fwebpack:webpack\",\n      \"outputs\": [\"{options.outputPath}\"],\n      \"defaultConfiguration\": \"production\",\n      \"options\": {\n        \"compiler\": \"babel\",\n        \"outputPath\": \"dist\u002Fapps\u002Fweb\",\n        \"index\": \"apps\u002Fweb\u002Fsrc\u002Findex.html\",\n        \"main\": \"apps\u002Fweb\u002Fsrc\u002Fmain.tsx\",\n        \"tsConfig\": \"apps\u002Fweb\u002Ftsconfig.app.json\",\n        \"assets\": [\"apps\u002Fweb\u002Fsrc\u002Fassets\"],\n        \"styles\": [\"apps\u002Fweb\u002Fsrc\u002Fstyles.css\"]\n      },\n      \"configurations\": {\n        \"development\": {\n          \"extractLicenses\": false,\n          \"optimization\": false,\n          \"sourceMap\": true\n        },\n        \"production\": {\n          \"optimization\": true,\n          \"outputHashing\": \"all\",\n          \"sourceMap\": false,\n          \"extractLicenses\": true\n        }\n      }\n    },\n    \"serve\": {\n      \"executor\": \"@nx\u002Fwebpack:dev-server\",\n      \"defaultConfiguration\": \"development\",\n      \"options\": {\n        \"buildTarget\": \"web:build\"\n      },\n      \"configurations\": {\n        \"development\": {\n          \"buildTarget\": \"web:build:development\"\n        },\n        \"production\": {\n          \"buildTarget\": \"web:build:production\"\n        }\n      }\n    },\n    \"test\": {\n      \"executor\": \"@nx\u002Fjest:jest\",\n      \"outputs\": [\"{workspaceRoot}\u002Fcoverage\u002F{projectRoot}\"],\n      \"options\": {\n        \"jestConfig\": \"apps\u002Fweb\u002Fjest.config.ts\",\n        \"passWithNoTests\": true\n      }\n    },\n    \"lint\": {\n      \"executor\": \"@nx\u002Feslint:lint\",\n      \"outputs\": [\"{options.outputFile}\"],\n      \"options\": {\n        \"lintFilePatterns\": [\"apps\u002Fweb\u002F**\u002F*.{ts,tsx,js,jsx}\"]\n      }\n    }\n  }\n}\n```\n\n### Template 3: Module Boundary Rules\n\n```json\n\u002F\u002F .eslintrc.json\n{\n  \"root\": true,\n  \"ignorePatterns\": [\"**\u002F*\"],\n  \"plugins\": [\"@nx\"],\n  \"overrides\": [\n    {\n      \"files\": [\"*.ts\", \"*.tsx\", \"*.js\", \"*.jsx\"],\n      \"rules\": {\n        \"@nx\u002Fenforce-module-boundaries\": [\n          \"error\",\n          {\n            \"enforceBuildableLibDependency\": true,\n            \"allow\": [],\n            \"depConstraints\": [\n              {\n                \"sourceTag\": \"type:app\",\n                \"onlyDependOnLibsWithTags\": [\n                  \"type:feature\",\n                  \"type:ui\",\n                  \"type:data-access\",\n                  \"type:util\"\n                ]\n              },\n              {\n                \"sourceTag\": \"type:feature\",\n                \"onlyDependOnLibsWithTags\": [\n                  \"type:ui\",\n                  \"type:data-access\",\n                  \"type:util\"\n                ]\n              },\n              {\n                \"sourceTag\": \"type:ui\",\n                \"onlyDependOnLibsWithTags\": [\"type:ui\", \"type:util\"]\n              },\n              {\n                \"sourceTag\": \"type:data-access\",\n                \"onlyDependOnLibsWithTags\": [\"type:data-access\", \"type:util\"]\n              },\n              {\n                \"sourceTag\": \"type:util\",\n                \"onlyDependOnLibsWithTags\": [\"type:util\"]\n              },\n              {\n                \"sourceTag\": \"scope:web\",\n                \"onlyDependOnLibsWithTags\": [\"scope:web\", \"scope:shared\"]\n              },\n              {\n                \"sourceTag\": \"scope:api\",\n                \"onlyDependOnLibsWithTags\": [\"scope:api\", \"scope:shared\"]\n              },\n              {\n                \"sourceTag\": \"scope:shared\",\n                \"onlyDependOnLibsWithTags\": [\"scope:shared\"]\n              }\n            ]\n          }\n        ]\n      }\n    }\n  ]\n}\n```\n\n### Template 4: Custom Generator\n\n```typescript\n\u002F\u002F tools\u002Fgenerators\u002Ffeature-lib\u002Findex.ts\nimport {\n  Tree,\n  formatFiles,\n  generateFiles,\n  joinPathFragments,\n  names,\n  readProjectConfiguration,\n} from '@nx\u002Fdevkit';\nimport { libraryGenerator } from '@nx\u002Freact';\n\ninterface FeatureLibraryGeneratorSchema {\n  name: string;\n  scope: string;\n  directory?: string;\n}\n\nexport default async function featureLibraryGenerator(\n  tree: Tree,\n  options: FeatureLibraryGeneratorSchema\n) {\n  const { name, scope, directory } = options;\n  const projectDirectory = directory\n    ? `${directory}\u002F${name}`\n    : `libs\u002F${scope}\u002Ffeature-${name}`;\n\n  \u002F\u002F Generate base library\n  await libraryGenerator(tree, {\n    name: `feature-${name}`,\n    directory: projectDirectory,\n    tags: `type:feature,scope:${scope}`,\n    style: 'css',\n    skipTsConfig: false,\n    skipFormat: true,\n    unitTestRunner: 'jest',\n    linter: 'eslint',\n  });\n\n  \u002F\u002F Add custom files\n  const projectConfig = readProjectConfiguration(tree, `${scope}-feature-${name}`);\n  const projectNames = names(name);\n\n  generateFiles(\n    tree,\n    joinPathFragments(__dirname, 'files'),\n    projectConfig.sourceRoot,\n    {\n      ...projectNames,\n      scope,\n      tmpl: '',\n    }\n  );\n\n  await formatFiles(tree);\n}\n```\n\n### Template 5: CI Configuration with Affected\n\n```yaml\n# .github\u002Fworkflows\u002Fci.yml\nname: CI\n\non:\n  push:\n    branches: [main]\n  pull_request:\n    branches: [main]\n\nenv:\n  NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}\n\njobs:\n  main:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions\u002Fcheckout@v4\n        with:\n          fetch-depth: 0\n\n      - uses: actions\u002Fsetup-node@v4\n        with:\n          node-version: 20\n          cache: 'npm'\n\n      - name: Install dependencies\n        run: npm ci\n\n      - name: Derive SHAs for affected commands\n        uses: nrwl\u002Fnx-set-shas@v4\n\n      - name: Run affected lint\n        run: npx nx affected -t lint --parallel=3\n\n      - name: Run affected test\n        run: npx nx affected -t test --parallel=3 --configuration=ci\n\n      - name: Run affected build\n        run: npx nx affected -t build --parallel=3\n\n      - name: Run affected e2e\n        run: npx nx affected -t e2e --parallel=1\n```\n\n### Template 6: Remote Caching Setup\n\n```typescript\n\u002F\u002F nx.json with Nx Cloud\n{\n  \"tasksRunnerOptions\": {\n    \"default\": {\n      \"runner\": \"nx-cloud\",\n      \"options\": {\n        \"cacheableOperations\": [\"build\", \"lint\", \"test\", \"e2e\"],\n        \"accessToken\": \"your-nx-cloud-token\",\n        \"parallel\": 3,\n        \"cacheDirectory\": \".nx\u002Fcache\"\n      }\n    }\n  },\n  \"nxCloudAccessToken\": \"your-nx-cloud-token\"\n}\n\n\u002F\u002F Self-hosted cache with S3\n{\n  \"tasksRunnerOptions\": {\n    \"default\": {\n      \"runner\": \"@nx-aws-cache\u002Fnx-aws-cache\",\n      \"options\": {\n        \"cacheableOperations\": [\"build\", \"lint\", \"test\"],\n        \"awsRegion\": \"us-east-1\",\n        \"awsBucket\": \"my-nx-cache-bucket\",\n        \"awsProfile\": \"default\"\n      }\n    }\n  }\n}\n```\n\n## Common Commands\n\n```bash\n# Generate new library\nnx g @nx\u002Freact:lib feature-auth --directory=libs\u002Fweb --tags=type:feature,scope:web\n\n# Run affected tests\nnx affected -t test --base=main\n\n# View dependency graph\nnx graph\n\n# Run specific project\nnx build web --configuration=production\n\n# Reset cache\nnx reset\n\n# Run migrations\nnx migrate latest\nnx migrate --run-migrations\n```\n\n## Best Practices\n\n### Do's\n- **Use tags consistently** - Enforce with module boundaries\n- **Enable caching early** - Significant CI savings\n- **Keep libs focused** - Single responsibility\n- **Use generators** - Ensure consistency\n- **Document boundaries** - Help new developers\n\n### Don'ts\n- **Don't create circular deps** - Graph should be acyclic\n- **Don't skip affected** - Test only what changed\n- **Don't ignore boundaries** - Tech debt accumulates\n- **Don't over-granularize** - Balance lib count\n\n## Resources\n\n- [Nx Documentation](https:\u002F\u002Fnx.dev\u002Fgetting-started\u002Fintro)\n- [Module Boundaries](https:\u002F\u002Fnx.dev\u002Fcore-features\u002Fenforce-module-boundaries)\n- [Nx Cloud](https:\u002F\u002Fnx.app\u002F)\n","# Nx Workspace Patterns\n\nProduction patterns for Nx monorepo management.\n\n## Do not use this skill when\n\n- The task is unrelated to nx workspace patterns\n- You need a different domain or tool outside this scope\n\n## Instructions\n\n- Clarify goals, constraints, and required inputs.\n- Apply relevant best practices and validate outcomes.\n- Provide actionable steps and verification.\n- If detailed examples are required, open `resources\u002Fimplementation-playbook.md`.\n\n## Use this skill when\n\n- Setting up new Nx workspaces\n- Configuring project boundaries\n- Optimizing CI with affected commands\n- Implementing remote caching\n- Managing dependencies between projects\n- Migrating to Nx\n\n## Core Concepts\n\n### 1. Nx Architecture\n\n```\nworkspace\u002F\n├── apps\u002F              # Deployable applications\n│   ├── web\u002F\n│   └── api\u002F\n├── libs\u002F              # Shared libraries\n│   ├── shared\u002F\n│   │   ├── ui\u002F\n│   │   └── utils\u002F\n│   └── feature\u002F\n│       ├── auth\u002F\n│       └── dashboard\u002F\n├── tools\u002F             # Custom executors\u002Fgenerators\n├── nx.json            # Nx configuration\n└── workspace.json     # Project configuration\n```\n\n### 2. Library Types\n\n| Type | Purpose | Example |\n|------|---------|---------|\n| **feature** | Smart components, business logic | `feature-auth` |\n| **ui** | Presentational components | `ui-buttons` |\n| **data-access** | API calls, state management | `data-access-users` |\n| **util** | Pure functions, helpers | `util-formatting` |\n| **shell** | App bootstrapping | `shell-web` |\n\n## Templates\n\n### Template 1: nx.json Configuration\n\n```json\n{\n  \"$schema\": \".\u002Fnode_modules\u002Fnx\u002Fschemas\u002Fnx-schema.json\",\n  \"npmScope\": \"myorg\",\n  \"affected\": {\n    \"defaultBase\": \"main\"\n  },\n  \"tasksRunnerOptions\": {\n    \"default\": {\n      \"runner\": \"nx\u002Ftasks-runners\u002Fdefault\",\n      \"options\": {\n        \"cacheableOperations\": [\n          \"build\",\n          \"lint\",\n          \"test\",\n          \"e2e\",\n          \"build-storybook\"\n        ],\n        \"parallel\": 3\n      }\n    }\n  },\n  \"targetDefaults\": {\n    \"build\": {\n      \"dependsOn\": [\"^build\"],\n      \"inputs\": [\"production\", \"^production\"],\n      \"cache\": true\n    },\n    \"test\": {\n      \"inputs\": [\"default\", \"^production\", \"{workspaceRoot}\u002Fjest.preset.js\"],\n      \"cache\": true\n    },\n    \"lint\": {\n      \"inputs\": [\"default\", \"{workspaceRoot}\u002F.eslintrc.json\"],\n      \"cache\": true\n    },\n    \"e2e\": {\n      \"inputs\": [\"default\", \"^production\"],\n      \"cache\": true\n    }\n  },\n  \"namedInputs\": {\n    \"default\": [\"{projectRoot}\u002F**\u002F*\", \"sharedGlobals\"],\n    \"production\": [\n      \"default\",\n      \"!{projectRoot}\u002F**\u002F?(*.)+(spec|test).[jt]s?(x)?(.snap)\",\n      \"!{projectRoot}\u002Ftsconfig.spec.json\",\n      \"!{projectRoot}\u002Fjest.config.[jt]s\",\n      \"!{projectRoot}\u002F.eslintrc.json\"\n    ],\n    \"sharedGlobals\": [\n      \"{workspaceRoot}\u002Fbabel.config.json\",\n      \"{workspaceRoot}\u002Ftsconfig.base.json\"\n    ]\n  },\n  \"generators\": {\n    \"@nx\u002Freact\": {\n      \"application\": {\n        \"style\": \"css\",\n        \"linter\": \"eslint\",\n        \"bundler\": \"webpack\"\n      },\n      \"library\": {\n        \"style\": \"css\",\n        \"linter\": \"eslint\"\n      },\n      \"component\": {\n        \"style\": \"css\"\n      }\n    }\n  }\n}\n```\n\n### Template 2: Project Configuration\n\n```json\n\u002F\u002F apps\u002Fweb\u002Fproject.json\n{\n  \"name\": \"web\",\n  \"$schema\": \"..\u002F..\u002Fnode_modules\u002Fnx\u002Fschemas\u002Fproject-schema.json\",\n  \"sourceRoot\": \"apps\u002Fweb\u002Fsrc\",\n  \"projectType\": \"application\",\n  \"tags\": [\"type:app\", \"scope:web\"],\n  \"targets\": {\n    \"build\": {\n      \"executor\": \"@nx\u002Fwebpack:webpack\",\n      \"outputs\": [\"{options.outputPath}\"],\n      \"defaultConfiguration\": \"production\",\n      \"options\": {\n        \"compiler\": \"babel\",\n        \"outputPath\": \"dist\u002Fapps\u002Fweb\",\n        \"index\": \"apps\u002Fweb\u002Fsrc\u002Findex.html\",\n        \"main\": \"apps\u002Fweb\u002Fsrc\u002Fmain.tsx\",\n        \"tsConfig\": \"apps\u002Fweb\u002Ftsconfig.app.json\",\n        \"assets\": [\"apps\u002Fweb\u002Fsrc\u002Fassets\"],\n        \"styles\": [\"apps\u002Fweb\u002Fsrc\u002Fstyles.css\"]\n      },\n      \"configurations\": {\n        \"development\": {\n          \"extractLicenses\": false,\n          \"optimization\": false,\n          \"sourceMap\": true\n        },\n        \"production\": {\n          \"optimization\": true,\n          \"outputHashing\": \"all\",\n          \"sourceMap\": false,\n          \"extractLicenses\": true\n        }\n      }\n    },\n    \"serve\": {\n      \"executor\": \"@nx\u002Fwebpack:dev-server\",\n      \"defaultConfiguration\": \"development\",\n      \"options\": {\n        \"buildTarget\": \"web:build\"\n      },\n      \"configurations\": {\n        \"development\": {\n          \"buildTarget\": \"web:build:development\"\n        },\n        \"production\": {\n          \"buildTarget\": \"web:build:production\"\n        }\n      }\n    },\n    \"test\": {\n      \"executor\": \"@nx\u002Fjest:jest\",\n      \"outputs\": [\"{workspaceRoot}\u002Fcoverage\u002F{projectRoot}\"],\n      \"options\": {\n        \"jestConfig\": \"apps\u002Fweb\u002Fjest.config.ts\",\n        \"passWithNoTests\": true\n      }\n    },\n    \"lint\": {\n      \"executor\": \"@nx\u002Feslint:lint\",\n      \"outputs\": [\"{options.outputFile}\"],\n      \"options\": {\n        \"lintFilePatterns\": [\"apps\u002Fweb\u002F**\u002F*.{ts,tsx,js,jsx}\"]\n      }\n    }\n  }\n}\n```\n\n### Template 3: Module Boundary Rules\n\n```json\n\u002F\u002F .eslintrc.json\n{\n  \"root\": true,\n  \"ignorePatterns\": [\"**\u002F*\"],\n  \"plugins\": [\"@nx\"],\n  \"overrides\": [\n    {\n      \"files\": [\"*.ts\", \"*.tsx\", \"*.js\", \"*.jsx\"],\n      \"rules\": {\n        \"@nx\u002Fenforce-module-boundaries\": [\n          \"error\",\n          {\n            \"enforceBuildableLibDependency\": true,\n            \"allow\": [],\n            \"depConstraints\": [\n              {\n                \"sourceTag\": \"type:app\",\n                \"onlyDependOnLibsWithTags\": [\n                  \"type:feature\",\n                  \"type:ui\",\n                  \"type:data-access\",\n                  \"type:util\"\n                ]\n              },\n              {\n                \"sourceTag\": \"type:feature\",\n                \"onlyDependOnLibsWithTags\": [\n                  \"type:ui\",\n                  \"type:data-access\",\n                  \"type:util\"\n                ]\n              },\n              {\n                \"sourceTag\": \"type:ui\",\n                \"onlyDependOnLibsWithTags\": [\"type:ui\", \"type:util\"]\n              },\n              {\n                \"sourceTag\": \"type:data-access\",\n                \"onlyDependOnLibsWithTags\": [\"type:data-access\", \"type:util\"]\n              },\n              {\n                \"sourceTag\": \"type:util\",\n                \"onlyDependOnLibsWithTags\": [\"type:util\"]\n              },\n              {\n                \"sourceTag\": \"scope:web\",\n                \"onlyDependOnLibsWithTags\": [\"scope:web\", \"scope:shared\"]\n              },\n              {\n                \"sourceTag\": \"scope:api\",\n                \"onlyDependOnLibsWithTags\": [\"scope:api\", \"scope:shared\"]\n              },\n              {\n                \"sourceTag\": \"scope:shared\",\n                \"onlyDependOnLibsWithTags\": [\"scope:shared\"]\n              }\n            ]\n          }\n        ]\n      }\n    }\n  ]\n}\n```\n\n### Template 4: Custom Generator\n\n```typescript\n\u002F\u002F tools\u002Fgenerators\u002Ffeature-lib\u002Findex.ts\nimport {\n  Tree,\n  formatFiles,\n  generateFiles,\n  joinPathFragments,\n  names,\n  readProjectConfiguration,\n} from '@nx\u002Fdevkit';\nimport { libraryGenerator } from '@nx\u002Freact';\n\ninterface FeatureLibraryGeneratorSchema {\n  name: string;\n  scope: string;\n  directory?: string;\n}\n\nexport default async function featureLibraryGenerator(\n  tree: Tree,\n  options: FeatureLibraryGeneratorSchema\n) {\n  const { name, scope, directory } = options;\n  const projectDirectory = directory\n    ? `${directory}\u002F${name}`\n    : `libs\u002F${scope}\u002Ffeature-${name}`;\n\n  \u002F\u002F Generate base library\n  await libraryGenerator(tree, {\n    name: `feature-${name}`,\n    directory: projectDirectory,\n    tags: `type:feature,scope:${scope}`,\n    style: 'css',\n    skipTsConfig: false,\n    skipFormat: true,\n    unitTestRunner: 'jest',\n    linter: 'eslint',\n  });\n\n  \u002F\u002F Add custom files\n  const projectConfig = readProjectConfiguration(tree, `${scope}-feature-${name}`);\n  const projectNames = names(name);\n\n  generateFiles(\n    tree,\n    joinPathFragments(__dirname, 'files'),\n    projectConfig.sourceRoot,\n    {\n      ...projectNames,\n      scope,\n      tmpl: '',\n    }\n  );\n\n  await formatFiles(tree);\n}\n```\n\n### Template 5: CI Configuration with Affected\n\n```yaml\n# .github\u002Fworkflows\u002Fci.yml\nname: CI\n\non:\n  push:\n    branches: [main]\n  pull_request:\n    branches: [main]\n\nenv:\n  NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}\n\njobs:\n  main:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions\u002Fcheckout@v4\n        with:\n          fetch-depth: 0\n\n      - uses: actions\u002Fsetup-node@v4\n        with:\n          node-version: 20\n          cache: 'npm'\n\n      - name: Install dependencies\n        run: npm ci\n\n      - name: Derive SHAs for affected commands\n        uses: nrwl\u002Fnx-set-shas@v4\n\n      - name: Run affected lint\n        run: npx nx affected -t lint --parallel=3\n\n      - name: Run affected test\n        run: npx nx affected -t test --parallel=3 --configuration=ci\n\n      - name: Run affected build\n        run: npx nx affected -t build --parallel=3\n\n      - name: Run affected e2e\n        run: npx nx affected -t e2e --parallel=1\n```\n\n### Template 6: Remote Caching Setup\n\n```typescript\n\u002F\u002F nx.json with Nx Cloud\n{\n  \"tasksRunnerOptions\": {\n    \"default\": {\n      \"runner\": \"nx-cloud\",\n      \"options\": {\n        \"cacheableOperations\": [\"build\", \"lint\", \"test\", \"e2e\"],\n        \"accessToken\": \"your-nx-cloud-token\",\n        \"parallel\": 3,\n        \"cacheDirectory\": \".nx\u002Fcache\"\n      }\n    }\n  },\n  \"nxCloudAccessToken\": \"your-nx-cloud-token\"\n}\n\n\u002F\u002F Self-hosted cache with S3\n{\n  \"tasksRunnerOptions\": {\n    \"default\": {\n      \"runner\": \"@nx-aws-cache\u002Fnx-aws-cache\",\n      \"options\": {\n        \"cacheableOperations\": [\"build\", \"lint\", \"test\"],\n        \"awsRegion\": \"us-east-1\",\n        \"awsBucket\": \"my-nx-cache-bucket\",\n        \"awsProfile\": \"default\"\n      }\n    }\n  }\n}\n```\n\n## Common Commands\n\n```bash\n# Generate new library\nnx g @nx\u002Freact:lib feature-auth --directory=libs\u002Fweb --tags=type:feature,scope:web\n\n# Run affected tests\nnx affected -t test --base=main\n\n# View dependency graph\nnx graph\n\n# Run specific project\nnx build web --configuration=production\n\n# Reset cache\nnx reset\n\n# Run migrations\nnx migrate latest\nnx migrate --run-migrations\n```\n\n## Best Practices\n\n### Do's\n- **Use tags consistently** - Enforce with module boundaries\n- **Enable caching early** - Significant CI savings\n- **Keep libs focused** - Single responsibility\n- **Use generators** - Ensure consistency\n- **Document boundaries** - Help new developers\n\n### Don'ts\n- **Don't create circular deps** - Graph should be acyclic\n- **Don't skip affected** - Test only what changed\n- **Don't ignore boundaries** - Tech debt accumulates\n- **Don't over-granularize** - Balance lib count\n\n## Resources\n\n- [Nx Documentation](https:\u002F\u002Fnx.dev\u002Fgetting-started\u002Fintro)\n- [Module Boundaries](https:\u002F\u002Fnx.dev\u002Fcore-features\u002Fenforce-module-boundaries)\n- [Nx Cloud](https:\u002F\u002Fnx.app\u002F)\n",{"name":5,"description":7},"main","def8531e65114c0fca8fb8551c1871ee0eed705c","skills\u002Faiskillstore\u002Fmarketplace\u002Fsickn33\u002Fnx-workspace-patterns",24,"https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub","https:\u002F\u002Fskillshub.wtf","https:\u002F\u002Fgithub.com\u002FComeOnOliver","AI & Blockchain Engineer\r\n","2026-06-24 22:07:19",{"source":8,"skillName":5,"commands":50,"prompt":60,"zipAvailable":61},[51,54,57],{"tool":52,"command":53},"npx","npx skills add ComeOnOliver\u002Fskillshub --skill nx-workspace-patterns",{"tool":55,"command":56},"bunx","bunx skills add ComeOnOliver\u002Fskillshub --skill nx-workspace-patterns",{"tool":58,"command":59},"pnpm","pnpm dlx skills add ComeOnOliver\u002Fskillshub --skill nx-workspace-patterns","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Faiskillstore\u002Fmarketplace\u002Fsickn33\u002Fnx-workspace-patterns\u002FSKILL.md",true,[63],{"path":64,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":67,"sourceHtmlUrl":68},"skill-report.json","REFERENCE","参考文档",8291,"https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Faiskillstore\u002Fmarketplace\u002Fsickn33\u002Fnx-workspace-patterns\u002Fskill-report.json",[70,84,94,103,109,116],{"skillNo":71,"name":72,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":73,"categories":74,"keywords":80,"publishedAt":35},"01M6FKJN13GMG4KY57J3QD8GY5","model-hierarchy-skill","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzscole\u002Fmodel-hierarchy-skill\u002Fmodel-hierarchy-skill\u002FSKILL.md",[75],{"categoryNo":76,"categoryName":77,"taxonomyType":78,"taxonomyTypeDesc":79},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[81,82,83],"model","model hierarchy","model hierarchy skill",{"skillNo":85,"name":86,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":87,"categories":88,"keywords":90,"publishedAt":35},"01M6FKJJJ6GCAMR4PPPRD12M5X","zoom-mcp","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fzoom-mcp\u002FSKILL.md",[89],{"categoryNo":76,"categoryName":77,"taxonomyType":78,"taxonomyTypeDesc":79},[91,92,93],"MCP","zoom","zoom mcp",{"skillNo":95,"name":96,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":97,"categories":98,"keywords":99,"publishedAt":35},"01M6FKJE3KYT3KPEZMEEHYKA6K","zoom-apps-sdk","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fzoom-apps-sdk\u002FSKILL.md",[],[100,101,102,92],"sdk","zoom apps sdk","apps",{"skillNo":104,"name":105,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":35},"01M6FKJ9EDH9Q5VWDF8HAJRSP0","windows","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwindows\u002FSKILL.md",[],[105],{"skillNo":110,"name":111,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":112,"categories":113,"keywords":115,"publishedAt":35},"01M6FKJ666BEEFC3AE9GJ72Q93","whiteboard","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwhiteboard\u002FSKILL.md",[114],{"categoryNo":76,"categoryName":77,"taxonomyType":78,"taxonomyTypeDesc":79},[111],{"skillNo":117,"name":118,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":119,"categories":120,"keywords":121,"publishedAt":35},"01M6FKJ21WFCDGTJQ2Q91T9DVW","websockets","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwebsockets\u002FSKILL.md",[],[118]]