Skip to content

Commit

Permalink
Remove airbnb style from eslint config
Browse files Browse the repository at this point in the history
  • Loading branch information
xmatthias committed Feb 5, 2022
1 parent 58d4283 commit 54862c0
Show file tree
Hide file tree
Showing 8 changed files with 41 additions and 495 deletions.
1 change: 0 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ module.exports = {
extends: [
// vue/recommended includes all higher levels (vue/strongly-recommended, vue/essential)
'plugin:vue/recommended',
'@vue/airbnb',
'@vue/typescript/recommended',
'@vue/prettier',
'@vue/prettier/@typescript-eslint',
Expand Down
6 changes: 2 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
"build": "vite build --mode prod",
"test:unit": "jest",
"check-types": "tsc --noemit",
"lint": "eslint",
"lint-ci": "eslint --no-fix",
"lint": "eslint --ext .ts,vue src tests",
"lint-ci": "eslint --no-fix --ext .ts,vue src tests",
"cy:open": "cypress open",
"cy:run": "cypress run",
"cy:open-ct": "cypress open-ct",
Expand Down Expand Up @@ -46,13 +46,11 @@
"@types/jest": "^27.4.0",
"@typescript-eslint/eslint-plugin": "^2.33.0",
"@typescript-eslint/parser": "^5.10.2",
"@vue/eslint-config-airbnb": "^5.1.0",
"@vue/eslint-config-prettier": "^6.0.0",
"@vue/eslint-config-typescript": "^5.1.0",
"@vue/test-utils": "^1.3.0",
"cypress": "^9.4.1",
"eslint": "^6.7.2",
"eslint-config-airbnb": "^18.2.1",
"eslint-plugin-prettier": "^3.4.1",
"eslint-plugin-vue": "^7.20.0",
"jest": "~26.6.3",
Expand Down
15 changes: 9 additions & 6 deletions src/env.d.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
/* Provide Type for Vite's import.meta.env structure */
interface ImportMetaEnv extends Readonly<Record<string, string>> {
readonly BASE_URL: string;
readonly MODE: string;
readonly PROD: boolean;
readonly DEV: boolean;
}

// eslint-disable-next-line @typescript-eslint/no-unused-vars
interface ImportMeta {
env: {
BASE_URL: string;
MODE: string;
PROD: boolean;
DEV: boolean;
};
readonly env: ImportMetaEnv;
}
13 changes: 6 additions & 7 deletions src/router/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const routes: Array<RouteConfig> = [
{
path: '/backtest',
name: 'Freqtrade Backtest',
component: () => import( '@/views/Backtesting.vue'),
component: () => import('@/views/Backtesting.vue'),
},
{
path: '/dashboard',
Expand All @@ -45,27 +45,26 @@ const routes: Array<RouteConfig> = [
{
path: '/balance',
name: 'Freqtrade Balance',
component: () => import(/* webpackChunkName: "balance" */ '@/components/ftbot/Balance.vue'),
component: () => import('@/components/ftbot/Balance.vue'),
},
{
path: '/open_trades',
component: () => import(/* webpackChunkName: "trades" */ '@/views/TradesList.vue'),
component: () => import('@/views/TradesList.vue'),
},

{
path: '/trade_history',
component: () => import(/* webpackChunkName: "trades" */ '@/views/TradesList.vue'),
component: () => import('@/views/TradesList.vue'),
props: { history: true },
},
{
path: '/pairlist',
component: () =>
import(/* webpackChunkName: "pairlist" */ '@/components/ftbot/FTBotAPIPairList.vue'),
component: () => import('@/components/ftbot/FTBotAPIPairList.vue'),
},
{
path: '/settings',
name: 'Freqtrade Settings',
component: () => import( '@/views/Settings.vue'),
component: () => import('@/views/Settings.vue'),
},
{
path: '/login',
Expand Down
2 changes: 1 addition & 1 deletion src/store/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ const store = new Vuex.Store({
UserService.migrateLogin();

store.registerModule(StoreModules.ftbot, createBotStore(store));
Object.entries(UserService.getAvailableBots()).forEach(([k, v]) => {
Object.entries(UserService.getAvailableBots()).forEach(([, v]) => {
store.dispatch(`${StoreModules.ftbot}/addBot`, v);
});
store.dispatch(`${StoreModules.ftbot}/selectFirstBot`);
Expand Down
2 changes: 1 addition & 1 deletion src/store/modules/botStoreWrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ export default function createBotStore(store) {
[MultiBotStoreGetters.allDailyStatsAllBots](state: FTMultiBotState, getters): DailyReturnValue {
const resp: Record<string, DailyRecord> = {};
getters.allAvailableBotsList.forEach((botId) => {
const x = getters[`${botId}/${BotStoreGetters.dailyStats}`]?.data?.forEach((d) => {
getters[`${botId}/${BotStoreGetters.dailyStats}`]?.data?.forEach((d) => {
if (!resp[d.date]) {
resp[d.date] = { ...d };
} else {
Expand Down
6 changes: 4 additions & 2 deletions src/views/Error404.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
<div>
<h1 class="mb-5">404 Error.</h1>
<p class="h4">Ahhhhhhhh! The page you are looking for does not exist.</p>
<p>Don't worry, you can head back to <router-link to="/">
<span>the main page</span></router-link>.</p>
<p>
Don't worry, you can head back to
<router-link to="/"> <span>the main page</span> </router-link>.
</p>
</div>
</template>

Expand Down
Loading

0 comments on commit 54862c0

Please sign in to comment.