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

Fixes broken NPM package (hopefully) #1413

Merged
merged 5 commits into from Dec 27, 2023

Conversation

mhayes
Copy link
Contributor

@mhayes mhayes commented Dec 26, 2023

Summary

Hey, thanks for putting together this package it seems super useful! Anyways while I was attempting to use the latest version of this package (0.18.1) it looks like dist/package.json is pointing to several files that don't actually appear to exist resulting in some runtime errors (documented in #1403):

Fixes #1403

dist/esm/index.js
dist/cjs/index.js
dist/typings/index.d.ts

When I cloned this package locally and ran yarn build it looks like everything is actually being built to dist/src like so:

dist
├── cjs
│   └── src
│       └── open-api
├── esm
│   └── src
│       └── open-api
└── typings
    └── src
        └── open-api

In this PR I just updated tsconfig.json to remove the rootDir. Running yarn build with that change builds out the correct directory structure:

dist
├── cjs
│   └── open-api
├── esm
│   └── open-api
└── typings
    └── open-api

Does this seem like the right fix? I also saw that bob the build tool was being used but couldn't figure out if there was some way to pass this configuration setting to that tool.

Copy link

changeset-bot bot commented Dec 26, 2023

🦋 Changeset detected

Latest commit: 999f507

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
sofa-api Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@ardatan
Copy link
Collaborator

ardatan commented Dec 27, 2023

Thanks for the PR! I did some small changes. We'll cut a release soon!

@ardatan ardatan merged commit ef9ffb6 into Urigo:master Dec 27, 2023
6 checks passed
@mhayes
Copy link
Contributor Author

mhayes commented Dec 27, 2023

Thanks @ardatan, that was fast!

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.

Broken NPM package
2 participants