mirror of https://github.com/OpenVidu/openvidu.git
openvidu-components: Added prettier
parent
3c97ceac37
commit
31f5206f01
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
"singleQuote": true,
|
||||
"printWidth": 140,
|
||||
"trailingComma": "none",
|
||||
"semi": true,
|
||||
"bracketSpacing": true,
|
||||
"useTabs": true,
|
||||
"jsxSingleQuote": true,
|
||||
"tabWidth": 4
|
||||
}
|
|
@ -1,2 +1 @@
|
|||
|
||||
<router-outlet></router-outlet>
|
||||
<router-outlet></router-outlet>
|
||||
|
|
|
@ -2,30 +2,28 @@ import { TestBed, async } from '@angular/core/testing';
|
|||
import { AppComponent } from './app.component';
|
||||
|
||||
describe('AppComponent', () => {
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [
|
||||
AppComponent
|
||||
],
|
||||
}).compileComponents();
|
||||
}));
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [AppComponent]
|
||||
}).compileComponents();
|
||||
}));
|
||||
|
||||
it('should create the app', () => {
|
||||
const fixture = TestBed.createComponent(AppComponent);
|
||||
const app = fixture.componentInstance;
|
||||
expect(app).toBeTruthy();
|
||||
});
|
||||
it('should create the app', () => {
|
||||
const fixture = TestBed.createComponent(AppComponent);
|
||||
const app = fixture.componentInstance;
|
||||
expect(app).toBeTruthy();
|
||||
});
|
||||
|
||||
it(`should have as title 'openvidu-components'`, () => {
|
||||
const fixture = TestBed.createComponent(AppComponent);
|
||||
const app = fixture.componentInstance;
|
||||
expect(app.title).toEqual('openvidu-components');
|
||||
});
|
||||
it(`should have as title 'openvidu-components'`, () => {
|
||||
const fixture = TestBed.createComponent(AppComponent);
|
||||
const app = fixture.componentInstance;
|
||||
expect(app.title).toEqual('openvidu-components');
|
||||
});
|
||||
|
||||
it('should render title', () => {
|
||||
const fixture = TestBed.createComponent(AppComponent);
|
||||
fixture.detectChanges();
|
||||
const compiled = fixture.nativeElement;
|
||||
expect(compiled.querySelector('.content span').textContent).toContain('openvidu-components app is running!');
|
||||
});
|
||||
it('should render title', () => {
|
||||
const fixture = TestBed.createComponent(AppComponent);
|
||||
fixture.detectChanges();
|
||||
const compiled = fixture.nativeElement;
|
||||
expect(compiled.querySelector('.content span').textContent).toContain('openvidu-components app is running!');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -10,5 +10,4 @@ export class AppComponent implements OnInit {
|
|||
constructor() {}
|
||||
|
||||
ngOnInit() {}
|
||||
|
||||
}
|
||||
|
|
|
@ -16,33 +16,35 @@ import { ChatTestComponent } from './components/chat-test/chat-test.component';
|
|||
import { LayoutTestComponent } from './components/layout-test/layout-test.component';
|
||||
import { ParticipantTestComponent } from './components/participant-test/participant-test.component';
|
||||
|
||||
import { OpenviduAngularModule, UserSettingsComponent, ChatComponent, ToolbarComponent, RoomComponent, LayoutComponent } from 'openvidu-angular';
|
||||
import {
|
||||
OpenviduAngularModule,
|
||||
UserSettingsComponent,
|
||||
ChatComponent,
|
||||
ToolbarComponent,
|
||||
RoomComponent,
|
||||
LayoutComponent,
|
||||
VideoconferenceComponent
|
||||
} from 'openvidu-angular';
|
||||
import { MatButtonModule } from '@angular/material/button';
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
AppComponent,
|
||||
DashboardComponent,
|
||||
CallComponent,
|
||||
ToolbarTestComponent,
|
||||
ChatTestComponent,
|
||||
LayoutTestComponent,
|
||||
ParticipantTestComponent
|
||||
],
|
||||
imports: [
|
||||
BrowserModule,
|
||||
MatButtonModule,
|
||||
BrowserAnimationsModule,
|
||||
OpenviduAngularModule.forRoot(environment),
|
||||
AppRoutingModule // Order is important, AppRoutingModule must be the last import for useHash working
|
||||
],
|
||||
providers: [
|
||||
UserSettingsComponent,
|
||||
ToolbarComponent,
|
||||
ChatComponent,
|
||||
RoomComponent,
|
||||
LayoutComponent
|
||||
],
|
||||
bootstrap: [AppComponent]
|
||||
declarations: [
|
||||
AppComponent,
|
||||
DashboardComponent,
|
||||
CallComponent,
|
||||
ToolbarTestComponent,
|
||||
ChatTestComponent,
|
||||
LayoutTestComponent,
|
||||
ParticipantTestComponent
|
||||
],
|
||||
imports: [
|
||||
BrowserModule,
|
||||
MatButtonModule,
|
||||
BrowserAnimationsModule,
|
||||
OpenviduAngularModule.forRoot(environment),
|
||||
AppRoutingModule // Order is important, AppRoutingModule must be the last import for useHash working
|
||||
],
|
||||
providers: [VideoconferenceComponent, UserSettingsComponent, ToolbarComponent, ChatComponent, RoomComponent, LayoutComponent],
|
||||
bootstrap: [AppComponent]
|
||||
})
|
||||
export class AppModule { }
|
||||
export class AppModule {}
|
||||
|
|
|
@ -7,19 +7,16 @@ import { ChatTestComponent } from './components/chat-test/chat-test.component';
|
|||
import { LayoutTestComponent } from './components/layout-test/layout-test.component';
|
||||
import { ParticipantTestComponent } from './components/participant-test/participant-test.component';
|
||||
|
||||
|
||||
|
||||
const routes: Routes = [
|
||||
{ path: '', component: DashboardComponent },
|
||||
{ path: 'call', component: CallComponent },
|
||||
{ path: 'toolbar', component: ToolbarTestComponent },
|
||||
{ path: 'chat', component: ChatTestComponent },
|
||||
{ path: 'layout', component: LayoutTestComponent },
|
||||
{ path: 'participant', component: ParticipantTestComponent },
|
||||
|
||||
{ path: 'participant', component: ParticipantTestComponent }
|
||||
];
|
||||
@NgModule({
|
||||
imports: [RouterModule.forRoot(routes, {useHash: true})],
|
||||
exports: [RouterModule],
|
||||
imports: [RouterModule.forRoot(routes, { useHash: true })],
|
||||
exports: [RouterModule]
|
||||
})
|
||||
export class AppRoutingModule { }
|
||||
export class AppRoutingModule {}
|
||||
|
|
|
@ -2,13 +2,11 @@ import { Component, OnInit } from '@angular/core';
|
|||
import { RestService } from '../services/rest.service';
|
||||
import { Router } from '@angular/router';
|
||||
|
||||
|
||||
@Component({
|
||||
selector: 'app-call',
|
||||
templateUrl: './call.component.html',
|
||||
styleUrls: ['./call.component.scss']
|
||||
})
|
||||
|
||||
export class CallComponent implements OnInit {
|
||||
sessionId = 'prueba-majestuosa-amable';
|
||||
tokens: { webcam: string; screen: string };
|
||||
|
|
|
@ -3,14 +3,14 @@ import { TestBed } from '@angular/core/testing';
|
|||
import { RestService } from './rest.service';
|
||||
|
||||
describe('RestService', () => {
|
||||
let service: RestService;
|
||||
let service: RestService;
|
||||
|
||||
beforeEach(() => {
|
||||
TestBed.configureTestingModule({});
|
||||
service = TestBed.inject(RestService);
|
||||
});
|
||||
beforeEach(() => {
|
||||
TestBed.configureTestingModule({});
|
||||
service = TestBed.inject(RestService);
|
||||
});
|
||||
|
||||
it('should be created', () => {
|
||||
expect(service).toBeTruthy();
|
||||
});
|
||||
it('should be created', () => {
|
||||
expect(service).toBeTruthy();
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue