0

I have recently included Angular 2 in my project. After setup, facing issue for namespace webdriver. On Google I found the solution here. But here it is asking to execute below npm command.

npm install @types/selenium-webdriver@2.53.36 --save-dev

Now, I want to know, where I will execute this above command, so that the required files will get included in my project.

Inside the VS IDE, I haven't found any console area like as for nuget, where I execute the command and files get included in project.

Please help.

Community
  • 1
  • 1
  • are you using this in Visual Studio? if so, what version of VS? – JamTay317 Jan 11 '17 at 01:10
  • I am using Visual Studio 2015. I am hoping that npm have console interface like Nuget package manager console – Vaibhav Agrawal Jan 11 '17 at 01:16
  • its tricky, but you dont need to do npm Install on the projetct. VS can you can have a pacakge.json file that will do everything for you. When I use Angular2 in VS 2015 I dont use any Console at all – JamTay317 Jan 11 '17 at 01:19
  • I will type this in the anwser if you would like? – JamTay317 Jan 11 '17 at 01:21
  • Yes, I have package.json in my project. But how do I use that to install selenium webdriver in my project, like as advised – Vaibhav Agrawal Jan 11 '17 at 01:25
  • please see answer below you can just add it to the package.json – JamTay317 Jan 11 '17 at 01:29
  • Thanks, but what and where in package.json file I have to write so that selenium webdriver related files get include in my project. Please refer the solution above that I referred and advise me related to that – Vaibhav Agrawal Jan 11 '17 at 01:40

1 Answers1

0
  1. add a nmp configuration file
  2. add all of the @angular dependencys that you will be needing
  3. add system.config file in the root of the project
  4. add tsconfig.json to the root of the project
  5. add tslint.json to root of project
  6. then add your app.component .module .route and other files.
  7. in system.config.js add your @angular/core and others like

    '@angular/core': 'npm:@angular/core@2.1.1/bundles/core.umd.js'

after doing this your can run your project and your _layout page is where you will add all of your <script> and other angular files.

JamTay317
  • 1,017
  • 3
  • 18
  • 37
  • Thanks JamTay, but all these files are present in my project like you said above. I want to know what and where I have to write [some code], so that selenium webdriver related files get include in my project – Vaibhav Agrawal Jan 11 '17 at 01:37