DEV Community

Discussion on: How to Create and Publish a React Component Library

Collapse
 
aayani profile image
Wahaj Aayani

Well written and very concise. But on a side note, has any one came across the issue while doing $ rollup -c?

Error: Could not resolve entry module (dist/esm/types/index.d.ts)

Collapse
 
smitterhane profile image
Smitter
Collapse
 
idontchop profile image
Nathan Dunn

Could be skipped the first step, making a component to export.

Collapse
 
salimzade profile image
Teymur Salimzade

just change dist/esm/types/index.d.ts -> dist/esm/index.d.ts

Collapse
 
alexeagleson profile image
Alex Eagleson

That command means "run rollup with the configuration found in rollup.config.js"

So I would start by making sure your config file looks exactly like the example and all the dependencies are installed

From this section:

dev.to/alexeagleson/how-to-create-...

Collapse
 
walachian profile image
Ovidiu-Deliu

I've stumbled upon the same issue. It is an issue with the rollup/plugin-typescript that has been also reported here:

github.com/rollup/plugins/issues/1230

You can follow the instructions there to get a workaround or just do the workaround from here:
github.com/alexeagleson/template-r...

Collapse
 
trandinhhiep789 profile image
eltr

Hi Wahaj Aayani
Did you fixed it?

Collapse
 
zakariaels profile image
Zakaria EL AISSAOUI • Edited

Have you found a fix to this issue ?

Collapse
 
trandinhhiep789 profile image
eltr
Thread Thread
 
zakariaels profile image
Zakaria EL AISSAOUI

Thank you :)

Some comments have been hidden by the post's author - find out more