Title: Salsa - reference search across commonjs fails · Issue #6682 · microsoft/TypeScript · GitHub
Open Graph Title: Salsa - reference search across commonjs fails · Issue #6682 · microsoft/TypeScript
X Title: Salsa - reference search across commonjs fails · Issue #6682 · microsoft/TypeScript
Description: In the following setup: version: typescript@1.9.0-dev.20160127 jsconfig.json { "compilerOptions": { "module": "commonjs", "target": "es5" }, "exclude": [ "node_modules" ] } circle.js const PI = Math.PI; exports.area = function (r) { retu...
Open Graph Description: In the following setup: version: typescript@1.9.0-dev.20160127 jsconfig.json { "compilerOptions": { "module": "commonjs", "target": "es5" }, "exclude": [ "node_modules" ] } circle.js const PI = Mat...
X Description: In the following setup: version: typescript@1.9.0-dev.20160127 jsconfig.json { "compilerOptions": { "module": "commonjs", "target": "es5" }, "...
Opengraph URL: https://github.com/microsoft/TypeScript/issues/6682
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Salsa - reference search across commonjs fails","articleBody":"In the following setup:\n\nversion: `typescript@1.9.0-dev.20160127`\n\njsconfig.json\n\n``` json\n{\n \"compilerOptions\": {\n \"module\": \"commonjs\",\n \"target\": \"es5\"\n },\n \"exclude\": [\n \"node_modules\"\n ]\n}\n```\n\ncircle.js\n\n``` javascript\nconst PI = Math.PI;\n\nexports.area = function (r) {\n return PI * r * r;\n};\n```\n\ngeometry.js\n\n``` javascript\nconst circle = require('./circle.js');\nconsole.log( `The area of a circle of radius 4 is ${circle.area(4)}`);\n```\n\nGo to definition from geometry.js `area` works and navigates to the file circle.js.\n\nDoing a reference search from circle.js exports.area doesn't result in any references.\n\nWhen changing the code of circle.js to:\n\n``` javascript\nconst PI = Math.PI;\n\nexport function area (r) {\n return PI * r * r;\n};\n```\n\nthen the reference search returns the correct result.\n","author":{"url":"https://github.com/egamma","@type":"Person","name":"egamma"},"datePublished":"2016-01-27T22:38:44Z","url":"https://github.com/microsoft/TypeScript/issues/6682"}
| 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:ef93406d-2f6b-7c3a-2bce-3c437805e80b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B152:363D8E:259211B:2FA6C0B:6B017432 |
| html-safe-nonce | 919b2dae17b153dc19d63a129eff6ef6dc9ad3631a7f248777f5f16e9715c683 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCMTUyOjM2M0Q4RToyNTkyMTFCOjJGQTZDMEI6NkIwMTc0MzIiLCJ2aXNpdG9yX2lkIjoiMzgzNTIwMTQ4NTUyODk4NjY3NCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | a1ce30cfc84b3f7c7601a13c17fd62517499a200037bf57dc3263f5cd77931a1 |
| hovercard-subject-tag | issue:129292950 |
| 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/6682/issue_layout |
| twitter:image | https://opengraph.githubassets.com/f38274d3c68f2e44e64d02678c036cb181d48a579064ad421da443389cbed158/microsoft/TypeScript/issues/6682 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/f38274d3c68f2e44e64d02678c036cb181d48a579064ad421da443389cbed158/microsoft/TypeScript/issues/6682 |
| og:image:alt | In the following setup: version: typescript@1.9.0-dev.20160127 jsconfig.json { "compilerOptions": { "module": "commonjs", "target": "es5" }, "exclude": [ "node_modules" ] } circle.js const PI = Mat... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | egamma |
| 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