HarveyD / react-component-library

A project skeleton to get your very own React Component Library up and running using Rollup, Typescript, SASS + Storybook
https://blog.harveydelaney.com/creating-your-own-react-component-library/
MIT License
790 stars 167 forks source link

Config for jsx #44

Open appleneilAM opened 2 years ago

appleneilAM commented 2 years ago

Hi Harvey,

I'm trying to follow your instructions but for .jsx files. When I run npm run build I get the following error

src/index.js → build/index.js, build/index.es.js...
[!] Error: Could not resolve './TestComponent/TestComponent' from src\index.js

Do you have any ideas?

pchr-srf commented 2 years ago

Did you add it to src/index.ts?

e.g.

import { TestComponent } from './TestComponent/TestComponent';

export { TestComponent };