.jsonc: 주석을 허용하는 JSON 확장 형식

  1. tasks: 각 태스크의 의존 관계 명시

    1. ready.dependesOn:^ready : 의존하는 ready 먼저 수행
      • ready.inputs:TURBO_DEFAULT,!**/*.md,!**/*.test.*: turbo의 기본 설정(git diff)은 모두 변경 사항으로 감지 but md 확장자, 테스트 코드는 감지 X
        • turbo repo는 이를 해시값으로 비교해 캐시를 활용할지 구분한다.
      • ready.outputs:dist/**,build/**: 캐싱할 빌드 결과물
        • 빌드 결과물은 .turbo에 저장한다.
    2. build.dependsOn:ready,^build: ready 수행 > 의존하는 build 먼저 수행
    3. dev.cache:false, dev.persistant:true: 개발 서버는 캐싱할 것이 없음
  2. boundaries: 패키지 경계 규칙

    1. 의존 관계 명시

      // turbo.json
      "boundaries": {
      	"tags": {
      		"app": {
      			"dependencies": { "deny": ["app"] }
      		},
      		"library": {
      			"dependencies": { "deny": ["app"] }
      		},
      		"infra": {
      			"dependencies": { "deny": ["app", "library"] }
      		},
      		"config": {
      			"dependencies": { "deny": ["app", "library", "infra"] }
      		}
      	}
      },
      

      패키지 경계 규칙: config → infra → library → app (하위 → 상위)

      • config: tsconfig, tailwind-config
      • infra: env, hmr, dev-utils, zipper, vite-config
      • library: shared, ui
      • app: chrome-extension, web, app, side-panel, options, content-ui, e2e
    2. 각 패키지 설정

      // tailwind-config/turbo.json
      { "extends": ["//"], "tags": ["config"] }
      
    3. CI에서 검사

      - name: Package boundaries
        run: turbo boundaries --filter="./packages/*"
      
  3. turbo devtools

  4. remote cache

    1. vercel link로 vercel에 연결

    2. github actions에서 환경 변수 설정

      // .github/workflows/ci-cd.yml
      jobs:
        ci:
          runs-on: ubuntu-latest
          env:
            TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
            TURBO_TEAM: ${{ secrets.TURBO_TEAM }}