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

Supporting d.ts files get excluded from dist #1797

Closed
jcfranco opened this issue Aug 8, 2019 · 2 comments
Closed

Supporting d.ts files get excluded from dist #1797

jcfranco opened this issue Aug 8, 2019 · 2 comments
Labels

Comments

@jcfranco
Copy link
Contributor

jcfranco commented Aug 8, 2019

Stencil version:

 @stencil/core@1.1.3

I'm submitting a:

[x] bug report
[ ] feature request
[ ] support request => Please do not submit support requests here, use one of these channels: https://stencil-worldwide.herokuapp.com/ or https://forum.ionicframework.com/

Current behavior:

Supporting src/components/interfaces.d.ts file is not included in dist/types/components/.

It is worth noting that dist/types/components.d.ts has the correct imports:

import { HTMLStencilElement, JSXBase } from '@stencil/core/internal';
import {
  Foo,
  Bar
} from './components/interfaces';

export namespace Test {
// ...

Expected behavior:

The output build includes dist/types/components/interfaces.d.ts.

Steps to reproduce:

*Assumes structure from component starter

  1. Add src/components/interfaces.d.ts (see below).
  2. Add a simple component and import from interfaces.d.ts
  3. Run the Stencil build.

Related code:

// interfaces.d.ts
export type Foo = "foo" | "Foo";

export type Bar = "bar" | "Bar";

Other information:

A workaround for this is to drop the declaration file extension and just use .ts (e.g., interfaces.ts)

@manucorporat
Copy link
Contributor

Can you test 1.15.0-2?

@jcfranco
Copy link
Contributor Author

@manucorporat Sorry for the delay. Sadly, I don't see the interfaces file included. Here's a repro repo if it helps: https://github.com/jcfranco/stencil-declaration-files-not-included-in-dist

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants