How to choose node js version?

How to choose node js version for ionic latest version for video streaming App.?

Go for the latest. Now 9.3.0 is available. Try that

tslint: C:/mediaStreaming/src/pages/home/home.ts, line: 2
All imports are unused.

L1: import { Component } from ‘@angular/core’;
L2: import { NavController } from ‘ionic-angular’;
L3: import { StreamingMedia, StreamingVideoOptions, StreamingAudioOption
s } from ‘@ionic-native/streaming-media’;

I got this error while i run ionic serve comment and also video doesn’t play… Any solution there.

This is not an error. Just a warning that you are not using the headers in your Component. Share your ts file

Which file i would share? app.html or full folder?

Please share your home.html and home.ts

Media Streaming Start Video

import { Component } from ‘@angular/core’;
import { NavController } from ‘ionic-angular’;
import { StreamingMedia, StreamingVideoOptions } from ‘@ionic-native/streaming-media’;

@Component({
selector: ‘page-home’,
templateUrl: ‘home.html’
})
export class HomePage {

constructor(private streamingMedia: StreamingMedia) { }

startVideo() {
let options: StreamingVideoOptions = {
successCallback: () => { console.log(‘Finished Video’) },
errorCallback: (e) => { console.log('Error: ', e) },
orientation: ‘portrait’
};

// http://www.sample-videos.com/
this.streamingMedia.playVideo('http://www.sample-videos.com/video/mp4/720/big_buck_bunny_720p_30mb.mp4', options);

}

}

Code is fine only. Hope you added the plugin in app.module.ts also.

If yes, it should work when the startVideo() function is called.

Try restarting your server and check. Better to check in device/emulator than checking in browser

okay i will try… thank… need one more help?

Post as a new topic if you have any other help

okay i will add new topic of it

Use the most recent LTS. Unless you program in Node, you don’t need track 9.

1 Like

If you are on Windows, ionic won’t even work with newest Node 9, Node LTS should be used.