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

Fix entry.d.ts missing exports #143

Merged
merged 1 commit into from
Nov 12, 2020
Merged

Conversation

fjc0k
Copy link
Contributor

@fjc0k fjc0k commented Nov 12, 2020

import {ArrayEntry, MapEntry, ObjectEntry, SetEntry} from './entry';

rollup-plugin-dts:

Error: 'ArrayEntry' is not exported by ****/node_modules/type-fest/source/entries.d.ts

@sindresorhus
Copy link
Owner

Those are internal types. I don't see why they need to be exported. Sounds like a bug in that plugin.

@fjc0k
Copy link
Contributor Author

fjc0k commented Nov 12, 2020

@sindresorhus

eeee, https://api-extractor.com/pages/overview/demo_rollup/:

Warning: node_modules/type-fest/source/entry.d.ts:55:1 - (ae-forgotten-export) The symbol "MapEntry" needs to be exported by the entry point index.d.ts
Warning: node_modules/type-fest/source/entry.d.ts:55:1 - (ae-forgotten-export) The symbol "SetEntry" needs to be exported by the entry point index.d.ts
Warning: node_modules/type-fest/source/entry.d.ts:55:1 - (ae-forgotten-export) The symbol "ArrayEntry" needs to be exported by the entry point index.d.ts
Warning: node_modules/type-fest/source/entry.d.ts:55:1 - (ae-forgotten-export) The symbol "ObjectEntry" needs to be exported by the entry point index.d.ts

@papb
Copy link
Contributor

papb commented Nov 12, 2020

Why do they 'need to be exported'?

@sindresorhus
Copy link
Owner

sindresorhus commented Nov 12, 2020

Ah, I get it now, because they're imported here:

import {ArrayEntry, MapEntry, ObjectEntry, SetEntry} from './entry';
Weird that TS allows this at all...

@sindresorhus sindresorhus merged commit 769e332 into sindresorhus:master Nov 12, 2020
@papb
Copy link
Contributor

papb commented Nov 12, 2020

Oh, wow. Indeed. Amazing.

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

Successfully merging this pull request may close these issues.

None yet

3 participants