-
Notifications
You must be signed in to change notification settings - Fork 262
Streamline search & install #552
Comments
This is how it used to work in 0.6. It didn't work well, mostly because people can't use prompts in a lot of locations (how do you handle more than one result?). Also, different sources can have exactly the same name for entirely different type definitions. I don't want to support automatically selecting one, this sounds like another hack for DefinitelyTyped because it's never been defined what it actually types.
I don't think so. I'd rather you understand what's going on. I already get too many issues asking why global sub-dependencies aren't automatically installed, I imagine this'll just make it more confusing by conflating the two. |
So what is the proposed solution to having to type and re-type install commands, guessing which one will work? |
There's a search command, as listed on the README. But no, there should only ever be one location appropriate for type definitions (plus DefinitelyTyped). |
So after a few days, I think adding the |
Yeah, it's definitely a bit lame. There's directions on the README for which sources are global and which aren't - the registry is strict about this. Unfortunately the same doesn't extend to |
--global does not resolve my issue. I keep getting this error Attempted to compile "aurelia-binding" as a global module, but it looks like an external module. Did you want to enable the global flag? I moved the typings " "aurelia-binding": "npm:aurelia-binding/dist/aurelia-binding.d.ts"," from globaldependecies to dependecies, it gives the same error for next module. If I move all the modules to dependencies that complain of this above error, it gives the duplicate error. Can anyone please help |
What's the duplicate error? Are you using jspm or npm? for npm you don't need to install at all. |
npm and webpack. So these are the steps:
Duplicate error is (and many others like these) error TS2300: Duplicate identifier 'message' |
Where? can you post the message? |
|
I mean the duplicate error. by the way, let's remove the |
Since you are using npm directly, you don't need to do |
This is the main error, I get duplicate error only when I move the aurelia "global dependencies" in "dependencies". I would like it to work while they are in global dependencies |
Here is my tsconfig
Here is my typings.json:
|
After removing aurelia-*, here is my typings.json:
and here are the errors after modifying typings.json and running "npm run dev":
|
This is because, both "modules" and "globals" folders under "typings" folder have same folders and files. |
Your old typings file is still there causing the dup errors. |
Since you are using windows. |
It does fine, when I run "typings install". But when I run "npm run dev", its the same. |
What's your |
"dev": "webpack-dev-server --config webpack.config.js --hot --inline --progress --devtool eval", |
Ok, don't know much about webpack... Does One thing you can try is to change |
Just checking, you DID delete the typings folder and |
yes, I deleted the folder and typings install again. |
@genericuser-me Dot not use Also, in the future, please open a new issue for unrelated issues - you've unfortunately made the completely legitimate feature request by another user illegible. Please open a new issue with the exact reproduction steps for help. Based on the information you've given, all I can say is don't make them global modules - they are external modules. |
Also, I don't think you need to use Typings for any of those dependencies anyway - if you're using TypeScript and node module resolution it will just work. |
Currently searching is unintuitive -- a user won't know what "dt" or "env" or "npm" sources are.
Automatically selecting the source would go a long way to improving the user experience.
Also there is a message when trying to install something, `Attempted to compile "blah" as an external module, but it looks like a global module."
Well it certainly makes sense for
typings
to automatically install it as a global module instead and not show the user that prompt at all, reducing the need for the user to re-run the identical command but with--global
added.The text was updated successfully, but these errors were encountered: