Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<reference types="" /> is not emitted when the dependency is indirect #15488

Closed
azz opened this issue May 1, 2017 · 3 comments · Fixed by #57681
Closed

<reference types="" /> is not emitted when the dependency is indirect #15488

azz opened this issue May 1, 2017 · 3 comments · Fixed by #57681
Labels
Bug A bug in TypeScript Effort: Moderate Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual". Fix Available A PR has been opened for this issue Help Wanted You can do this
Milestone

Comments

@azz
Copy link

azz commented May 1, 2017

TypeScript Version: 2.3.2

This is similar to #15487.

Code

// deps/dep/dep.d.ts
/// <reference path="indirect.d.ts" />
// deps/dep/indirect.d.ts
interface Dep {
}
// deps/dep/package.json
{
  "typings": "dep.d.ts"
}

// src/index.ts
class Src implements Dep {}

Compile with

// src/tsconfig.json
{
    "compilerOptions": {
        "declaration": true,
        "types": [
            "dep"
        ],
        "typeRoots": [
            "../deps"
        ]
    }
}

Expected behavior:

/// <reference types="dep" />
declare class Src implements Dep {
}

Actual behavior:

declare class Src implements Dep {
}

Tasks

No tasks being tracked yet.
@azz
Copy link
Author

azz commented May 1, 2017

Full repro here:
https://github.com/azz/typescript-issue-15488

azz added a commit to azz/TypeScript that referenced this issue May 1, 2017
@azz
Copy link
Author

azz commented May 1, 2017

Wrote up a test case, commit referenced above this comment.

@RyanCavanaugh RyanCavanaugh added the Needs Investigation This issue needs a team member to investigate its status. label May 24, 2017
@mhegazy mhegazy added Help Wanted You can do this Bug A bug in TypeScript and removed Needs Investigation This issue needs a team member to investigate its status. labels May 24, 2017
@mhegazy mhegazy added this to the Community milestone May 24, 2017
@mhegazy
Copy link
Contributor

mhegazy commented May 24, 2017

PRs welcomed.

@mhegazy mhegazy added the Effort: Moderate Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual". label May 24, 2017
@RyanCavanaugh RyanCavanaugh modified the milestones: Community, Backlog Mar 7, 2019
@typescript-bot typescript-bot added the Fix Available A PR has been opened for this issue label Mar 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A bug in TypeScript Effort: Moderate Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual". Fix Available A PR has been opened for this issue Help Wanted You can do this
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants