-
Notifications
You must be signed in to change notification settings - Fork 11
Unified "install" #3
Comments
When both It is good that we provide the flexibility and allow user to choose freely, but that ability to choose could also be a burden to the user as they need to know which one is more accurate. Any thoughts on that? Would it be possible to unify it and have a flag in the In that case, by default the module included typings would be used, but that default can be overridden if the non-github / private modules author can not maintain the included typing. This could also simplify the |
# from
typings install domready --name dr
# to
typings install dr=domready
# in jspm
jspm install dr=domready
jspm install dr=npm:domready
jspm install dr=github:ded/domready If ambientize to typings install domready
# in jspm
jpsm install domready Also, jspm install domready will update and typings install domready will update # from
typings install core-js --ambient
# to
typings install dt:core-js As we are getting the ambient version from DefinitelyTyped anyway. Ambientized external module declaration is (or suppose to) share the same shape as its ambient version, so: typings install npm:core-js --ambient
# is equivalent to
typings install npm:core-js From Blake: In general, I really like the idea but it's not compatible (npm:core-js). This scheme is already used to resolve (E.g. from node_modules, from GitHub, from file, etc), so this would be a major breaking change that I don't currently see as needed. I would like a better way to make these simpler, but breaking the current scheme isn't one. For now you could typings install core-js -s dt. The other issue is that these are "polyfill" typings. These aren't the same as installing the source code, there's an extra layer in the middle usually. E.g. NPM registry -> Typings registry (marked as npm) -> GitHub. As for the immediate save option, what about -D? I do like the idea of automatically writing as you install, just need a complete suggestion of what'll work differently. This is also another thing that would go to the next major release, not the current release train. Finally, I think the last suggestion is around automatically using ambient vs non-ambient? I'm sort of off for that because there's already a lot of confusion around the difference between ambient and normal dependencies, etc. and when the get resolved/installed/etc. I like the explicitness. One suggestion for these that I loved was having a default normal and ambient source when installing (which you actually suggested: #126 (comment)). |
Haha, I knew i missed something: ambient and unify + override. Let me try to explain a little more in what I mean unify approach:
If the user wants to override that, user can do UPDATE:
Query npm directly, jspm endpoint does similar things. Since we only get the package.json (similar to |
Will sort these idea out when I have time to |
Not sure if you resolved this, but I think I'm going to release this change with 0.7. The API/syntax will be |
Sounds good! |
In light of: Maybe we can simplify the syntax for most packages to |
Yep, that's the idea. I believe it's a discussion we had a long while back and has evolved little by little until today. a) 👍 |
About (b): By default, jspm install npm:domready
jspm install github:unional/unional-umd Adding entries in the registry.json allows user to: jspm install domready
jspm install unional-umd |
Right, but that's a mapping for a single registry. We're a mapping for multiple registries. I can't quite see how that'd work for everything, so I think (a) makes more sense here. At least on Bower/JSPM/etc. project you could check in a Edit: As always, you're open to try to convince me otherwise 😉 |
Yes Sir! 😜 |
This is a easy one: + npm
+ -- domready.json
+ registry.json // npm/domready.json
{
// the usual thing
"versions": { ... }
} // registry.json
{
"domready": "./npm/domready.json"
} 🍺 |
Yes, I understand the concern for bower/jspm does not go away with this approach. Need a bit more brainstorming. 😄 |
But on the other hand, if |
Right, but what does |
On your concern, it shouldn't be installed. In general, I don't want to just fallback to different sources - it could be an entirely different module. If it is the same module, we should have the entry under |
Sounds good. And that would address the version discrepancy issue too. |
Yes 👍 Right now, the implicit stuff seemed cool - but as I've discovered it's caused too many issues and implicit behaviours. I think this will be a good improvement, and killing the prompts will be amazing! |
And |
I start feeling "distribution channel" is too much typings. 😛 |
While this concern is valid and I also agree to it. 99% of the time it will work correctly. Just adding this comment to record this opinion. 😄 |
Referencing: And I think this can be closed. 😄 |
Placeholder for discussed ideas.
The text was updated successfully, but these errors were encountered: