---
title: "Comment by Aleksandar Mirilović on \"Publishing TypeScript React components to NPM\" | Hashnode"
description: "Good one Rupert! One question, if package that you are publishing is part of a workspace, would publishing from dist work? Most likely you need to build the pac"
url: "https://hashnode.com/posts/publishing-typescript-react-components-to-npm/60f30734bb67011cb8369b7f/comment/60f3173266fcdb0a02742804"
---

[Discussion](https://hashnode.com/posts/publishing-typescript-react-components-to-npm/60f30734bb67011cb8369b7f)

Comment [Publishing TypeScript React components to NPM](https://hashnode.com/posts/publishing-typescript-react-components-to-npm/60f30734bb67011cb8369b7f)

[Aleksandar Mirilović](https://hashnode.com/@amirilovic)

[Jul 17, 2021](https://hashnode.com/posts/publishing-typescript-react-components-to-npm/60f30734bb67011cb8369b7f/comment/60f3173266fcdb0a02742804)

Good one Rupert! One question, if package that you are publishing is part of a workspace, would publishing from dist work? Most likely you need to build the package and point main file to dist/index.js in order to use it elsewhere in the workspace, how would you deal with that?

[Rupert McKay](https://hashnode.com/@fildon)

[Oct 18, 2021](https://hashnode.com/posts/publishing-typescript-react-components-to-npm/60f30734bb67011cb8369b7f/comment/60f3173266fcdb0a02742804#reply-616d2dd0f1f4c944cc6b30e9)

Honestly, I've not had much experience with workspaces.

My usual inclination would be to coordinate via npm packages. But I know that's not everyone's preference.

I'd be really interested to read a write-up on how exactly the build process I've described above would need to change in a multi-workspace monorepo.
