Title: TS 3.7: --declaration output for getter only property now is a getter instead of `readonly` · Issue #33939 · microsoft/TypeScript · GitHub
Open Graph Title: TS 3.7: --declaration output for getter only property now is a getter instead of `readonly` · Issue #33939 · microsoft/TypeScript
X Title: TS 3.7: --declaration output for getter only property now is a getter instead of `readonly` · Issue #33939 · microsoft/TypeScript
Description: TypeScript Version: 3.7.0-dev.20191010 Search Terms: --declaration getter d.ts Repo: For the TS file foo.ts: export class Foo { get bar(): boolean { return true; } } Run tsc foo.ts --declaration Expected In TS 3.6, the output d.ts uses r...
Open Graph Description: TypeScript Version: 3.7.0-dev.20191010 Search Terms: --declaration getter d.ts Repo: For the TS file foo.ts: export class Foo { get bar(): boolean { return true; } } Run tsc foo.ts --declaration Ex...
X Description: TypeScript Version: 3.7.0-dev.20191010 Search Terms: --declaration getter d.ts Repo: For the TS file foo.ts: export class Foo { get bar(): boolean { return true; } } Run tsc foo.ts --declaration Ex...
Opengraph URL: https://github.com/microsoft/TypeScript/issues/33939
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"TS 3.7: --declaration output for getter only property now is a getter instead of `readonly`","articleBody":"\u003c!-- 🚨 STOP 🚨 𝗦𝗧𝗢𝗣 🚨 𝑺𝑻𝑶𝑷 🚨\r\n\r\nHalf of all issues filed here are duplicates, answered in the FAQ, or not appropriate for the bug tracker. Even if you think you've found a *bug*, please read the FAQ first, especially the Common \"Bugs\" That Aren't Bugs section!\r\n\r\nPlease help us by doing the following steps before logging an issue:\r\n * Search: https://github.com/Microsoft/TypeScript/search?type=Issues\r\n * Read the FAQ: https://github.com/Microsoft/TypeScript/wiki/FAQ\r\n\r\nPlease fill in the *entire* template below.\r\n-->\r\n\r\n\u003c!-- Please try to reproduce the issue with `typescript@next`. It may have already been fixed. -->\r\n**TypeScript Version:** 3.7.0-dev.20191010\r\n\r\n\u003c!-- Search terms you tried before logging this (so others can find this issue more easily) -->\r\n**Search Terms:**\r\n- `--declaration`\r\n- getter \r\n- d.ts\r\n\r\n**Repo:**\r\nFor the TS file `foo.ts`:\r\n\r\n```ts\r\nexport class Foo {\r\n get bar(): boolean { return true; }\r\n}\r\n```\r\n\r\n1. Run `tsc foo.ts --declaration`\r\n\r\n**Expected**\r\nIn TS 3.6, the output `d.ts` uses `readonly`:\r\n\r\n```ts\r\nexport declare class Foo {\r\n readonly bar: boolean;\r\n}\r\n```\r\n\r\n**Actual behavior:**\r\nIn TS 3.7, the output `d.ts` use a getter instead:\r\n\r\n```ts\r\nexport declare class Foo {\r\n get bar(): boolean;\r\n}\r\n```\r\n","author":{"url":"https://github.com/mjbvz","@type":"Person","name":"mjbvz"},"datePublished":"2019-10-10T23:37:23Z","url":"https://github.com/microsoft/TypeScript/issues/33939"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:cdfe0712-a792-5105-c051-1d8dcec6072b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | AC8E:26ECEB:2AE69B1:36889E1:6B0197E0 |
| html-safe-nonce | e6589d257dac5b95122225024e284aa0a50e124da008d72d4c1b0307fbac9ef5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBQzhFOjI2RUNFQjoyQUU2OUIxOjM2ODg5RTE6NkIwMTk3RTAiLCJ2aXNpdG9yX2lkIjoiNjU2NTU5NjI2NDI2MzU3NzI4IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | ae5d8b7fc3722ba1ed9912b701827a2f777f16af39de87e5f19f15be301f34a5 |
| hovercard-subject-tag | issue:505561992 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/microsoft/TypeScript/33939/issue_layout |
| twitter:image | https://opengraph.githubassets.com/b858b5fef5aa18cd8f65fb7aff56125e108c26704c297321ac2e49f1d7a9f3f8/microsoft/TypeScript/issues/33939 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/b858b5fef5aa18cd8f65fb7aff56125e108c26704c297321ac2e49f1d7a9f3f8/microsoft/TypeScript/issues/33939 |
| og:image:alt | TypeScript Version: 3.7.0-dev.20191010 Search Terms: --declaration getter d.ts Repo: For the TS file foo.ts: export class Foo { get bar(): boolean { return true; } } Run tsc foo.ts --declaration Ex... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | mjbvz |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/microsoft/TypeScript git https://github.com/microsoft/TypeScript.git |
| octolytics-dimension-user_id | 6154722 |
| octolytics-dimension-user_login | microsoft |
| octolytics-dimension-repository_id | 20929025 |
| octolytics-dimension-repository_nwo | microsoft/TypeScript |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 20929025 |
| octolytics-dimension-repository_network_root_nwo | microsoft/TypeScript |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width