IMERSS / inat-components

A suite of React components for rendering iNaturalist data.
https://imerss.github.io/inat-components/
MIT License
6 stars 1 forks source link

Fix awful shared/ folder #6

Open benkeen opened 1 year ago

benkeen commented 1 year ago

I recall running into plenty of problems here, so vouched for the simplest solution. But it sucks! Should be in a separate package or something. The grunt copy thing is awful.

amb26 commented 1 year ago

I did wonder about that - is the grunt shared copy part of an idiom from somewhere? Would you be able to run down some of the problems you ran into since I'd like to get a sense of the design tensions here.

benkeen commented 1 year ago

I'll have time this weekend to give this thing a look over. This one was really intractable though, I just don't recall the problems. Storing this as a separate internal package is obviously the logical arrangement so I'm sure I had a good reason (right? Right?).

benkeen commented 1 year ago

This is a really fussy one. I'm using rollup and the @rollup/plugin-typescript plugin to generate the bundle for @imerss/inat-components. Normally with TS you'd just use project references to import the code from that shared location, but it doesn't appear to be supported by the rollup plugin, as described here. I get the exact same error.

I don't much want to ditch rollup, but perhaps I'll look into parcel or something else.

benkeen commented 1 year ago

Ugh. Going to try Parcel. This is becoming a pain.