René's URL Explorer Experiment


Title: Generating Type Definitions from Javascript is blocked by requiring private name · Issue #37832 · microsoft/TypeScript · GitHub

Open Graph Title: Generating Type Definitions from Javascript is blocked by requiring private name · Issue #37832 · microsoft/TypeScript

X Title: Generating Type Definitions from Javascript is blocked by requiring private name · Issue #37832 · microsoft/TypeScript

Description: TypeScript Version: 3.9.0-dev.20200407 Search Terms: TS9006 Declaration emit for this file requires using private name Explicit type annotation Unblock declaration emit. Code // thing.js // maybe something from deep in my library 'use st...

Open Graph Description: TypeScript Version: 3.9.0-dev.20200407 Search Terms: TS9006 Declaration emit for this file requires using private name Explicit type annotation Unblock declaration emit. Code // thing.js // maybe s...

X Description: TypeScript Version: 3.9.0-dev.20200407 Search Terms: TS9006 Declaration emit for this file requires using private name Explicit type annotation Unblock declaration emit. Code // thing.js // maybe s...

Opengraph URL: https://github.com/microsoft/TypeScript/issues/37832

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Generating Type Definitions from Javascript is blocked by requiring private name","articleBody":"**TypeScript Version:**  3.9.0-dev.20200407\r\n\r\n**Search Terms:**\r\n- TS9006\r\n- Declaration emit for this file requires using private name\r\n- Explicit type annotation \r\n- Unblock declaration emit.\r\n\r\n**Code**\r\n```js\r\n// thing.js // maybe something from deep in my library\r\n'use strict';\r\nclass Thing {}\r\nmodule.exports = { Thing };\r\n```\r\n```js\r\n// index.js\r\n\"use strict\";\r\nconst Thing = require(\"./thing\").Thing;\r\nmodule.exports = { Thing }; // re-export to the world\r\n```\r\ntsconfig.json:\r\n```json\r\n{\r\n  \"compilerOptions\": {\r\n    \"allowJs\": true,\r\n    \"checkJs\": true,\r\n    \"declaration\": true,\r\n    \"emitDeclarationOnly\": true,\r\n    \"declarationDir\": \"types\",\r\n    \"strict\": false,\r\n    \"target\": \"ES2018\",\r\n    \"module\": \"commonJS\",\r\n    \"moduleResolution\": \"node\",\r\n    \"lib\": [\"ES2018\"]\r\n  },\r\n  \"include\": [\"index.js\", \"thing.js\"]\r\n}\r\n```\r\n\r\n**Expected behavior:**\r\nI believe I should get two declaration files out of this that would look something like:\r\n```ts\r\n// thing.d.ts\r\nexport class Thing {}\r\n```\r\n```ts\r\n// index.d.ts\r\nimport { Thing } from './thing';\r\nexport { Thing };\r\n```\r\n**Actual behavior:**\r\n`index.d.ts` fails to be emitted with the error:\r\n```\r\nTS9006: Declaration emit for this file requires using private name 'Thing' from module '\"/Users/neal/Desktop/privateNameTSC/thing\"'. An explicit type annotation may unblock declaration emit.\r\n```\r\nIt's not clear to me how to annotate the module.exports to make the \"name\" not private anymore\r\nThanks for taking a look.\r\n\r\n**Playground Link:** Can't because imports related but I made a minimum repro here: https://github.com/nbbeeken/private-name-error-tsc\r\n\r\n**Related Issues:** #9865\r\n","author":{"url":"https://github.com/nbbeeken","@type":"Person","name":"nbbeeken"},"datePublished":"2020-04-07T22:12:26Z","url":"https://github.com/microsoft/TypeScript/issues/37832"}

react-profiling0
react-import-mapreact,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-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:ea432ec1-fedd-87ef-d80a-291d52f31ba9
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idBAA8:2463BD:2B5D045:3760DA3:6B01A1FE
html-safe-nonce8b6bc813c683e4f511130d4276383f198ca501f20a3a87fea6aa3fc1616611d8
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQUE4OjI0NjNCRDoyQjVEMDQ1OjM3NjBEQTM6NkIwMUExRkUiLCJ2aXNpdG9yX2lkIjoiNjEzMTM1ODkzNTQ2ODMxOTIzMCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac1d11d1cd3a603199f7e551bf7f5641d404135e2e257be2dbc72eb7fa63e3c762
hovercard-subject-tagissue:596182480
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/microsoft/TypeScript/37832/issue_layout
twitter:imagehttps://opengraph.githubassets.com/ef9a6b9340b7362e4ad354b31683b471cee22f776c6c818f2094807aec54f21f/microsoft/TypeScript/issues/37832
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/ef9a6b9340b7362e4ad354b31683b471cee22f776c6c818f2094807aec54f21f/microsoft/TypeScript/issues/37832
og:image:altTypeScript Version: 3.9.0-dev.20200407 Search Terms: TS9006 Declaration emit for this file requires using private name Explicit type annotation Unblock declaration emit. Code // thing.js // maybe s...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamenbbeeken
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
turbo-cache-controlno-preview
go-importgithub.com/microsoft/TypeScript git https://github.com/microsoft/TypeScript.git
octolytics-dimension-user_id6154722
octolytics-dimension-user_loginmicrosoft
octolytics-dimension-repository_id20929025
octolytics-dimension-repository_nwomicrosoft/TypeScript
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id20929025
octolytics-dimension-repository_network_root_nwomicrosoft/TypeScript
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/microsoft/TypeScript/issues/37832#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmicrosoft%2FTypeScript%2Fissues%2F37832
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmicrosoft%2FTypeScript%2Fissues%2F37832
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=microsoft%2FTypeScript
Reloadhttps://github.com/microsoft/TypeScript/issues/37832
Reloadhttps://github.com/microsoft/TypeScript/issues/37832
Reloadhttps://github.com/microsoft/TypeScript/issues/37832
microsofthttps://github.com/microsoft
TypeScripthttps://github.com/microsoft/TypeScript
Codehttps://github.com/microsoft/TypeScript
Issues5k (5k)https://github.com/microsoft/TypeScript/issues
Pull requests312 (312)https://github.com/microsoft/TypeScript/pulls
Actionshttps://github.com/microsoft/TypeScript/actions
Projectshttps://github.com/microsoft/TypeScript/projects
Wikihttps://github.com/microsoft/TypeScript/wiki
Security and qualityhttps://github.com/microsoft/TypeScript/security
Insightshttps://github.com/microsoft/TypeScript/insights
https://github.com/microsoft/TypeScript
New issuehttps://github.com/login?return_to=https://github.com/microsoft/TypeScript/issues/37832
New issuehttps://github.com/login?return_to=https://github.com/microsoft/TypeScript/issues/37832
Generating Type Definitions from Javascript is blocked by requiring private namehttps://github.com/microsoft/TypeScript/issues/37832#top
https://github.com/weswigham
BugA bug in TypeScripthttps://github.com/microsoft/TypeScript/issues?q=state%3Aopen%20label%3A%22Bug%22
TypeScript 4.1.0https://github.com/microsoft/TypeScript/milestone/124
https://github.com/nbbeeken
Neal Beeken (nbbeeken)https://github.com/nbbeeken
on Apr 7, 2020https://github.com/microsoft/TypeScript/issues/37832#issue-596182480
https://github.com/nbbeeken/private-name-error-tschttps://github.com/nbbeeken/private-name-error-tsc
#9865https://github.com/microsoft/TypeScript/issues/9865
Nexthttps://github.com/microsoft/TypeScript/issues/37832?timeline_page=1
Nathan Shively-Sanders (sandersn)https://github.com/sandersn
BugA bug in TypeScripthttps://github.com/microsoft/TypeScript/issues?q=state%3Aopen%20label%3A%22Bug%22
on Apr 7, 2020https://github.com/microsoft/TypeScript/issues/37832#event-3211998152
Nathan Shively-Sanders (sandersn)https://github.com/sandersn
TypeScript 4.0https://github.com/microsoft/TypeScript/milestone/114
on Apr 7, 2020https://github.com/microsoft/TypeScript/issues/37832#event-3211998337
Nathan Shively-Sanders (sandersn)https://github.com/sandersn
Wesley Wigham (weswigham)https://github.com/weswigham
on Apr 7, 2020https://github.com/microsoft/TypeScript/issues/37832#event-3211998518
https://github.com/sandersn
Nathan Shively-Sanders (sandersn)https://github.com/sandersn
on Apr 7, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-610673404
https://github.com/mbroadst
Matt Broadstone (mbroadst)https://github.com/mbroadst
on Apr 8, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-610907238
Nathan Shively-Sanders (@sandersn)https://github.com/sandersn
https://github.com/sandersn
Nathan Shively-Sanders (sandersn)https://github.com/sandersn
on Apr 8, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-611063969
Wesley Wigham (@weswigham)https://github.com/weswigham
Wesley Wigham (@weswigham)https://github.com/weswigham
Matt Broadstone (@mbroadst)https://github.com/mbroadst
https://github.com/weswigham
Wesley Wigham (weswigham)https://github.com/weswigham
on Apr 8, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-611126910
Nathan Shively-Sanders (@sandersn)https://github.com/sandersn
Andreas Thomas (chronark)https://github.com/chronark
on May 10, 2020https://github.com/microsoft/TypeScript/issues/37832#event-3320512848
[feat] Add script to generate bcoin typeshttps://github.com/chronark/swapchain/commit/c5c4cff2d80d240b259bfe86d6d2e4fe3f20fb4b
c5c4cffhttps://github.com/chronark/swapchain/commit/c5c4cff2d80d240b259bfe86d6d2e4fe3f20fb4b
https://github.com/jamesopti
James Fox (jamesopti)https://github.com/jamesopti
on Jun 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-650323249
Ryan Cavanaugh (RyanCavanaugh)https://github.com/RyanCavanaugh
TypeScript 4.0https://github.com/microsoft/TypeScript/milestone/114
Typescript 4.0.1https://github.com/microsoft/TypeScript/milestone/123
on Jun 29, 2020https://github.com/microsoft/TypeScript/issues/37832#event-3493747657
https://github.com/Anton-Loginov
Anton_Loginov (Anton-Loginov)https://github.com/Anton-Loginov
on Jul 9, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-655919679
Neal Beeken (@nbbeeken)https://github.com/nbbeeken
https://github.com/nbbeeken
Neal Beeken (nbbeeken)https://github.com/nbbeeken
on Jul 9, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-656153081
Neal Beeken (@nbbeeken)https://github.com/nbbeeken
Nathan Shively-Sanders (sandersn)https://github.com/sandersn
TypeScript 4.0.1https://github.com/microsoft/TypeScript/milestone/123
TypeScript 4.1.0https://github.com/microsoft/TypeScript/milestone/124
on Jul 29, 2020https://github.com/microsoft/TypeScript/issues/37832#event-3601355637
https://github.com/glen-84
Glen (glen-84)https://github.com/glen-84
on Oct 25, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716120272
Bnaya Peretz (@Bnaya)https://github.com/Bnaya
stylelinthttps://github.com/stylelint/stylelint
https://github.com/Bnaya
Bnaya Peretz (Bnaya)https://github.com/Bnaya
on Oct 25, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716138739
Glen (@glen-84)https://github.com/glen-84
https://github.com/stylelint/stylelint/pull/5004/fileshttps://github.com/stylelint/stylelint/pull/5004/files
https://github.com/glen-84
Glen (glen-84)https://github.com/glen-84
on Oct 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716577903
Bnaya Peretz (@Bnaya)https://github.com/Bnaya
https://github.com/Bnaya
Bnaya Peretz (Bnaya)https://github.com/Bnaya
on Oct 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716581628
zouying (@typedef)https://github.com/typedef
https://github.com/glen-84
Glen (glen-84)https://github.com/glen-84
on Oct 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716591324
https://github.com/Bnaya
Bnaya Peretz (Bnaya)https://github.com/Bnaya
on Oct 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716594273
Types (@types)https://github.com/types
https://github.com/ggreco
Gabriele Greco (ggreco)https://github.com/ggreco
on Oct 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716604714
https://github.com/ggreco/doc2dechttps://github.com/ggreco/doc2dec
https://github.com/glen-84
Glen (glen-84)https://github.com/glen-84
on Oct 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716626657
Gabriele Greco (@ggreco)https://github.com/ggreco
https://github.com/Bnaya
Bnaya Peretz (Bnaya)https://github.com/Bnaya
on Oct 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716635974
https://github.com/ggreco/doc2dechttps://github.com/ggreco/doc2dec
https://github.com/ggreco
Gabriele Greco (ggreco)https://github.com/ggreco
on Oct 26, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-716687629
Gabriele Greco (@ggreco)https://github.com/ggreco
#41250https://github.com/microsoft/TypeScript/issues/41250
Bnaya Peretz (@Bnaya)https://github.com/Bnaya
https://github.com/weswigham
Wesley Wigham (weswigham)https://github.com/weswigham
on Oct 28, 2020https://github.com/microsoft/TypeScript/issues/37832#issuecomment-718204231
https://gist.github.com/Bnaya/f88130a9321b2706e1745f8695ff9664https://gist.github.com/Bnaya/f88130a9321b2706e1745f8695ff9664
Nico Bosshard (nicoboss)https://github.com/nicoboss
on Oct 21, 2021https://github.com/microsoft/TypeScript/issues/37832#event-5497668060
Definitionen für die neuste JIFF Bibliothek geschrieben. Besonders sc…https://github.com/nicoboss/practical-MPC/commit/04af5872fa1624bba5bc4a6b037079c98d85032f
04af587https://github.com/nicoboss/practical-MPC/commit/04af5872fa1624bba5bc4a6b037079c98d85032f
https://github.com/rajsite
Milan Raj (rajsite)https://github.com/rajsite
on Oct 17, 2022https://github.com/microsoft/TypeScript/issues/37832#issuecomment-1281206391
Neal Beeken (@nbbeeken)https://github.com/nbbeeken
Brandon Bennett (Offroaders123)https://github.com/Offroaders123
on Feb 12, 2024https://github.com/microsoft/TypeScript/issues/37832#event-11768882751
TSC Migrationhttps://github.com/Offroaders123/node-cdb/commit/0504d161a3ccdf6f9dbc8033e747eafc2bf4f58e
0504d16https://github.com/Offroaders123/node-cdb/commit/0504d161a3ccdf6f9dbc8033e747eafc2bf4f58e
microsofthttps://github.com/microsoft
on Oct 21, 2025https://github.com/microsoft/TypeScript/issues/37832#event-20416930764
Sign up for freehttps://github.com/signup?return_to=https://github.com/microsoft/TypeScript/issues/37832
Sign in to commenthttps://github.com/login?return_to=https://github.com/microsoft/TypeScript/issues/37832
Wesley Wigham (weswigham)https://github.com/weswigham
BugA bug in TypeScripthttps://github.com/microsoft/TypeScript/issues?q=state%3Aopen%20label%3A%22Bug%22
TypeScript 4.1.0https://github.com/microsoft/TypeScript/milestone/124
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.