Skip to content

Commit

Permalink
🎨 add prettier plugins and format code
Browse files Browse the repository at this point in the history
  • Loading branch information
yuudi committed Oct 24, 2024
1 parent f9cd2ae commit 24c64ef
Show file tree
Hide file tree
Showing 16 changed files with 241 additions and 28 deletions.
4 changes: 3 additions & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
{}
{
"plugins": ["prettier-plugin-organize-imports", "prettier-plugin-packagejson"]
}
209 changes: 208 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 12 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
{
"name": "rclone-webui-angular",
"version": "0.8.0",
"private": true,
"scripts": {
"ng": "ng",
"start": "ng serve",
"build:dev": "ng build --configuration development",
"build:embed": "ng build --configuration production,embed",
"build:standalone": "ng build --configuration production,standalone",
"build:native": "ng build --configuration production,native",
"watch": "ng build --watch --configuration development,embed",
"test": "ng test",
"lint:prettier": "prettier ./src --write",
"lint:eslint": "ng lint --fix",
"lint": "npm run lint:eslint && npm run lint:prettier",
"build:standalone": "ng build --configuration production,standalone",
"check-updates": "npm-check-updates",
"extract-i18n": "ng extract-i18n",
"check-updates": "npm-check-updates"
"lint": "npm run lint:eslint && npm run lint:prettier",
"lint:eslint": "ng lint --fix",
"lint:prettier": "prettier ./src --write",
"ng": "ng",
"start": "ng serve",
"test": "ng test",
"watch": "ng build --watch --configuration development,embed"
},
"private": true,
"dependencies": {
"@angular/animations": "^16.2.0",
"@angular/cdk": "^16.2.0",
Expand Down Expand Up @@ -56,6 +56,8 @@
"ng-extract-i18n-merge": "^2.7.0",
"npm-check-updates": "^16.10.18",
"prettier": "^3.0.1",
"prettier-plugin-organize-imports": "^4.1.0",
"prettier-plugin-packagejson": "^2.5.3",
"typescript": "~5.1.6"
}
}
2 changes: 1 addition & 1 deletion src/app/cores/storage/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export { AppStorageService } from './app-storage.service';
export {
AwaitableStorageItem,
ObservableAwaitableStorageItem,
} from './base-storage';
export { AppStorageService } from './app-storage.service';
2 changes: 1 addition & 1 deletion src/app/features/connection/connection-routing.module.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';

import { ConnectionComponent } from './connection.component';
import { ConnectionEditorComponent } from './connection-editor/connection-editor.component';
import { ConnectionComponent } from './connection.component';

const routes: Routes = [
{
Expand Down
2 changes: 1 addition & 1 deletion src/app/features/dashboard/dashboard.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import { Observable } from 'rxjs';
import packageJson from '../../../../package.json';
import { environment } from '../../../environments/environment';

import { DashboardService } from './dashboard.service';
import { RcloneVersionInfo, TransferStatus } from './dashboard.model';
import { DashboardService } from './dashboard.service';

@Component({
selector: 'app-dashboard',
Expand Down
2 changes: 1 addition & 1 deletion src/app/features/functions/backend/backend.component.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { Component, OnInit } from '@angular/core';

import { Observable, of } from 'rxjs';
import { Backend, BackendUsage } from './backend.model';
import { BackendService } from './backend.service';
import { Observable, of } from 'rxjs';

type Unmeasured = null;
const Unmeasured = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ import { MatDialog } from '@angular/material/dialog';
import { MatSnackBar } from '@angular/material/snack-bar';

import { ConnectionService } from 'src/app/cores/remote-control/connection.service';
import { AppStorageService } from 'src/app/cores/storage';
import { Err, Ok, Result } from 'src/app/shared/result';
import { SimpleDialogComponent } from 'src/app/shared/simple-dialog/simple-dialog.component';
import { AppProvider } from './new-backend.model';
import { NewBackendService } from './new-backend.service';
import { AppStorageService } from 'src/app/cores/storage';

@Component({
selector: 'app-new-backend',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { Injectable } from '@angular/core';
import { RemoteControlService } from 'src/app/cores/remote-control/remote-control.service';

import { AppProvider } from './new-backend.model';
import { RemoteControlService } from 'src/app/cores/remote-control/remote-control.service';
import { Ok, Result } from 'src/app/shared/result';
import { AppProvider } from './new-backend.model';

@Injectable({
providedIn: 'root',
})
Expand Down
3 changes: 2 additions & 1 deletion src/app/features/functions/cron/cron.component.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { Component, OnInit } from '@angular/core';

import { CronService, Schedular, Task } from './cron.service';
import { MatSnackBar } from '@angular/material/snack-bar';

import { CronService, Schedular, Task } from './cron.service';

@Component({
selector: 'app-cron',
templateUrl: './cron.component.html',
Expand Down
2 changes: 1 addition & 1 deletion src/app/features/functions/functions.module.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { NgModule } from '@angular/core';

import { FunctionsRoutingModule } from './functions-routing.module';
import { FunctionsComponent } from './functions.component';
Expand Down
Loading

0 comments on commit 24c64ef

Please sign in to comment.