style: format code
This commit is contained in:
parent
b2053acdfe
commit
f2aa81b6d2
5 changed files with 274 additions and 221 deletions
|
@ -1,17 +1,17 @@
|
|||
import { Injectable } from '@angular/core';
|
||||
import { HttpClient } from '@angular/common/http';
|
||||
import { Observable } from 'rxjs';
|
||||
import { DiceDto, DiceResult } from './dice.model';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class DiceService {
|
||||
private apiUrl = '/backend/dice';
|
||||
|
||||
constructor(private http: HttpClient) { }
|
||||
|
||||
rollDice(diceDto: DiceDto): Observable<DiceResult> {
|
||||
return this.http.post<DiceResult>(this.apiUrl, diceDto);
|
||||
}
|
||||
}
|
||||
import { Injectable } from '@angular/core';
|
||||
import { HttpClient } from '@angular/common/http';
|
||||
import { Observable } from 'rxjs';
|
||||
import { DiceDto, DiceResult } from './dice.model';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root',
|
||||
})
|
||||
export class DiceService {
|
||||
private apiUrl = '/backend/dice';
|
||||
|
||||
constructor(private http: HttpClient) {}
|
||||
|
||||
rollDice(diceDto: DiceDto): Observable<DiceResult> {
|
||||
return this.http.post<DiceResult>(this.apiUrl, diceDto);
|
||||
}
|
||||
}
|
||||
|
|
Reference in a new issue