-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
feat: provide API to load modules from npm registry #498
Conversation
antongolub
commented
Aug 24, 2022
•
edited
Loading
edited
- Tests pass
- Appropriate changes to README are included in PR
b85da5e
to
af1886f
Compare
af1886f
to
4644298
Compare
Awesome! Looks super cool. But let’s try to simplify a little bit. I have a few ideas 💡 |
src/internals.ts
Outdated
return {} | ||
} | ||
|
||
await $`npm install --no-save --no-audit --no-fund ${flags} ${pkgs}` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool 😎
deps
API to load modules from npm registry
src/cli.ts
Outdated
@@ -142,7 +142,7 @@ async function writeAndImport( | |||
if (argv.install) { | |||
await installDeps(parseDeps(contents), { | |||
prefix: dirname(filepath), | |||
registry: argv.registy, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can touse be passed via env args? To not pollute argv?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ZX_REGISTRY / ZX_USERCONFIG
?
or std npm_config_*
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome 😎
8227814
to
9d6ca3a
Compare
9d6ca3a
to
46aed65
Compare
I’m going to update dev branch, lets merge there. |