-
Notifications
You must be signed in to change notification settings - Fork 161
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
Improve NPM experience #33
Comments
Yes. I have been meaning to do this as well. Do you want to send me a PR ? |
For information on what types to include in the barrel for web and node environments, please take a look at the |
Can I just export everything? This is kinda supported already now. |
Also, since we include generated files in repo (OK for now), any particular commands you suggest before pushing? Run all the commands in readme in order? |
@tikurahul hey buddy. Have you had a chance to look at the Pull Request? (#34) Sorry if being a little pushy. There's some great work in here, and would love to see it easily consumable. Cheers, |
Oops, my browser was cached or something. Didn't see reply there. Will continue discussion there, sorry. |
Thanks for the contribution. 👍 |
Hello,
There are a few things that can make NPM usage (and TypeScript experience especially) a lot better.
src/index.ts
file thatexport
s all other files in that folder.main
property inpackage.json
that points to the compiled result of the barrel, ex:built/index.js
types
property inpackage.json
that points to the TypeScript declaration of the barrel, ex:built/index.d.ts
That'll allow people to
import * as appAuth from '@openid/appauth';
, or have more specificimport
s, as they wish.Documentation: TypeScript Docs: Publishing
P.S.
Thanks heaps for the great work on the library.
P.P.S.
If you agree with the concept, I can also create a PR for this.
The text was updated successfully, but these errors were encountered: