Skip to content
Advertisement

Tag: angular

Videogular 2 onChangeFullscreen event

I need to know how do I use the VgFullscreenAPI. The official documentation doesn’t help. This is what I have: I have tried using the output event emitter (onChangeFullscreen) on vg-plater, vg-fullscreen, and video tags. Documentation Answer The event is provided by the VgFullscreenAPI service inside VgPlayer, you can access it like this inside your component class: Don’t really know

Shared module imported in AppModule

I was reading the Angular documentation about modules, looking for a line that discourages importing a SharedModule inside the AppModule. I didn’t find anything about that, just a GitHub issue which states that it’s better not to import it. However without any deep explain… https://github.com/tomastrajan/angular-ngrx-material-starter/issues/47 Angular discourages providing services in the Shared modules, which indeed I agree. But nothing else.

Checking ‘undefined’ or ‘null’ of any Object

I am working on Angular project and time to time I used to have check undefined or null over Object or it’s properties. Normally I use lodash _.isUndefined() see example below: I couldn’t see any problem with it. But I had discussion with my colleague during review of above code. He was telling me that if i gets undefined before

Angular 4 setTimeout() with variable delay and wait

I have a list of events with timestamp. What I want is to display the events based on the timestamp: To add a delay: I know this doesn’t work well with setTimeout, but there is an workaround, if the timeout is constant, in my case is not. Is it possible to make the next setTimeout() wait for the previous one?

Advertisement