victory460 Posted December 3, 2017 Share Posted December 3, 2017 Hello, When I'm look about the link of https://reference.digilentinc.com/reference/software/digilent-instrumentation-protocol/angular2 In step 7 ,when I write import { DigilentChart } from 'digilent-chart-angular2/components'; in my project,it show a error so I replace it to import { DigilentChart } from 'digilent-chart-angular2/modules'; but when I add DigilentChart to declarations it get error my codes: and when I use the errors please help me Link to comment Share on other sites More sharing options...
sudharsan.sukumar Posted December 5, 2017 Share Posted December 5, 2017 Hi, I'm looking into this. My first idea is that it's probably an Angular version problem since dip-angluar2 was written in Angular2. I will keep you updated. Thanks, Dharsan Link to comment Share on other sites More sharing options...
sudharsan.sukumar Posted December 5, 2017 Share Posted December 5, 2017 Okay I know what the problem is. I'll update the documentation thank you for finding this. I've updated my ionic version to 3.19.0 (the latest version). This is what app.module.ts should say: import { BrowserModule } from '@angular/platform-browser'; import { NgModule, ErrorHandler } from '@angular/core'; import { IonicApp, IonicModule, IonicErrorHandler } from 'ionic-angular'; import { MyApp } from './app.component'; import { HelloIonicPage } from '../pages/hello-ionic/hello-ionic'; import { ItemDetailsPage } from '../pages/item-details/item-details'; import { ListPage } from '../pages/list/list'; import { StatusBar } from '@ionic-native/status-bar'; import { SplashScreen } from '@ionic-native/splash-screen'; import { DeviceManagerService } from 'dip-angular2/services'; import { DigilentChartModule } from 'digilent-chart-angular2/modules'; @NgModule({ declarations: [ MyApp, HelloIonicPage, ItemDetailsPage, ListPage ], imports: [ BrowserModule, IonicModule.forRoot(MyApp), DigilentChartModule ], bootstrap: [IonicApp], entryComponents: [ MyApp, HelloIonicPage, ItemDetailsPage, ListPage ], providers: [ StatusBar, SplashScreen, {provide: ErrorHandler, useClass: IonicErrorHandler}, DeviceManagerService ] }) export class AppModule {} Then you can follow the tutorial as normal. Note that DeviceService is just a type and cannot be instantiated and therefore cannot be added to the providers array. Instead we use it in hello-ionic.ts in order to get typing for an instance of the device in the DeviceManagerService. Let me know if you have any more questions, Dharsan Link to comment Share on other sites More sharing options...
sudharsan.sukumar Posted December 5, 2017 Share Posted December 5, 2017 Also, we're planning on coming out with a pure ts / js version of DIP that doesn't require Angular (though we still recommend using Angular/Ionic for large scale applications). If you're interested, I can send you an update here when we publish it within the next few weeks. -Dharsan Link to comment Share on other sites More sharing options...
victory460 Posted December 9, 2017 Author Share Posted December 9, 2017 On 2017/12/6 at 2:41 AM, sudharsan.sukumar said: Also, we're planning on coming out with a pure ts / js version of DIP that doesn't require Angular (though we still recommend using Angular/Ionic for large scale applications). If you're interested, I can send you an update here when we publish it within the next few weeks. -Dharsan Thanks a lot,I am interesting the pure ts / js version of DIP that doesn't require Angular,that‘s cool. it is best to combine a simple example, because I'm afraid I will not use it. Link to comment Share on other sites More sharing options...
sudharsan.sukumar Posted December 12, 2017 Share Posted December 12, 2017 Here's a link to the dip-js GitHub repository. Feel free to file issues there if you run into any bugs or have any feature requests. An example can be found in the examples directory but I recommend following the readme. Thanks, Dharsan Link to comment Share on other sites More sharing options...
victory460 Posted December 14, 2017 Author Share Posted December 14, 2017 On 2017/12/13 at 3:06 AM, sudharsan.sukumar said: Here's a link to the dip-js GitHub repository. Feel free to file issues there if you run into any bugs or have any feature requests. An example can be found in the examples directory but I recommend following the readme. Thanks, Dharsan Thanks a lot. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.