diff --git a/.chronus/changes/peer-dependencies-2024-9-10-22-53-58.md b/.chronus/changes/peer-dependencies-2024-9-10-22-53-58.md new file mode 100644 index 0000000000..f846ae4fa1 --- /dev/null +++ b/.chronus/changes/peer-dependencies-2024-9-10-22-53-58.md @@ -0,0 +1,7 @@ +--- +changeKind: internal +packages: + - "@typespec/compiler" +--- + +Set `@typespec/compiler` as a `peerDependency` in library templates \ No newline at end of file diff --git a/packages/compiler/templates/__snapshots__/emitter-ts/package.json b/packages/compiler/templates/__snapshots__/emitter-ts/package.json index e08b6c9604..be67451bea 100644 --- a/packages/compiler/templates/__snapshots__/emitter-ts/package.json +++ b/packages/compiler/templates/__snapshots__/emitter-ts/package.json @@ -13,13 +13,14 @@ "default": "./dist/src/testing/index.js" } }, - "dependencies": { + "peerDependencies": { "@typespec/compiler": "latest" }, "devDependencies": { "@types/node": "latest", "@typescript-eslint/eslint-plugin": "^6.0.0", "@typescript-eslint/parser": "^6.0.0", + "@typespec/compiler": "latest", "eslint": "^8.45.0", "typescript": "^5.3.3", "prettier": "^3.0.3" diff --git a/packages/compiler/templates/__snapshots__/library-ts/package.json b/packages/compiler/templates/__snapshots__/library-ts/package.json index 079f06ca5a..d9db6f4cac 100644 --- a/packages/compiler/templates/__snapshots__/library-ts/package.json +++ b/packages/compiler/templates/__snapshots__/library-ts/package.json @@ -14,13 +14,14 @@ "default": "./dist/src/testing/index.js" } }, - "dependencies": { + "peerDependencies": { "@typespec/compiler": "latest" }, "devDependencies": { "@types/node": "latest", "@typescript-eslint/eslint-plugin": "^6.0.0", "@typescript-eslint/parser": "^6.0.0", + "@typespec/compiler": "latest", "@typespec/library-linter": "latest", "eslint": "^8.45.0", "prettier": "^3.0.3", diff --git a/packages/compiler/templates/emitter-ts/package.json b/packages/compiler/templates/emitter-ts/package.json index 4806800b1b..70db6e13ab 100644 --- a/packages/compiler/templates/emitter-ts/package.json +++ b/packages/compiler/templates/emitter-ts/package.json @@ -13,13 +13,14 @@ "default": "./dist/src/testing/index.js" } }, - "dependencies": { + "peerDependencies": { "@typespec/compiler": "latest" }, "devDependencies": { "@types/node": "latest", "@typescript-eslint/eslint-plugin": "^6.0.0", "@typescript-eslint/parser": "^6.0.0", + "@typespec/compiler": "latest", "eslint": "^8.45.0", "typescript": "^5.3.3", "prettier": "^3.0.3" diff --git a/packages/compiler/templates/library-ts/package.json b/packages/compiler/templates/library-ts/package.json index 99014148a6..5ad106e7e1 100644 --- a/packages/compiler/templates/library-ts/package.json +++ b/packages/compiler/templates/library-ts/package.json @@ -14,13 +14,14 @@ "default": "./dist/src/testing/index.js" } }, - "dependencies": { + "peerDependencies": { "@typespec/compiler": "latest" }, "devDependencies": { "@types/node": "latest", "@typescript-eslint/eslint-plugin": "^6.0.0", "@typescript-eslint/parser": "^6.0.0", + "@typespec/compiler": "latest", "@typespec/library-linter": "latest", "eslint": "^8.45.0", "prettier": "^3.0.3",