Skip to content

Commit bc9687f

Browse files
committed
Update all packages and get site running again add code style check
1 parent 3f62673 commit bc9687f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+6195
-3233
lines changed

.eslintrc.js

+13-13
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
module.exports = {
2-
root: true,
3-
env: {
4-
node: true
5-
},
6-
extends: ["plugin:vue/essential", "@vue/prettier"],
7-
rules: {
8-
"no-console": process.env.NODE_ENV === "production" ? "error" : "off",
9-
"no-debugger": process.env.NODE_ENV === "production" ? "error" : "off",
10-
"indent": ["error", 4]
11-
},
12-
parserOptions: {
13-
parser: "babel-eslint"
14-
}
2+
root: true,
3+
env: {
4+
node: true
5+
},
6+
extends: ['plugin:vue/essential', '@vue/prettier'],
7+
rules: {
8+
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
9+
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
10+
indent: ['error', 4]
11+
},
12+
parserOptions: {
13+
parser: 'babel-eslint'
14+
}
1515
};

.prettierrc.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
module.exports = {
22
tabWidth: 4,
3-
'singleQuote': true
4-
};
3+
singleQuote: true
4+
};

.travis.yml

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ install:
77
- yarn install
88

99
script:
10+
- yarn lint
1011
- yarn test:unit
1112

1213
cache:

babel.config.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module.exports = {
2-
presets: ["@vue/app"]
2+
presets: ['@vue/app']
33
};

jest.config.js

+15-15
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
module.exports = {
2-
moduleFileExtensions: ["js", "jsx", "json", "vue"],
3-
transform: {
4-
"^.+\\.vue$": "vue-jest",
5-
".+\\.(css|styl|less|sass|scss|svg|png|jpg|ttf|woff|woff2)$":
6-
"jest-transform-stub",
7-
"^.+\\.jsx?$": "babel-jest"
8-
},
9-
moduleNameMapper: {
10-
"^@/(.*)$": "<rootDir>/src/$1"
11-
},
12-
snapshotSerializers: ["jest-serializer-vue"],
13-
testMatch: [
14-
"**/tests/unit/**/*.spec.(js|jsx|ts|tsx)|**/__tests__/*.(js|jsx|ts|tsx)"
15-
],
16-
testURL: "http://localhost/"
2+
moduleFileExtensions: ['js', 'jsx', 'json', 'vue'],
3+
transform: {
4+
'^.+\\.vue$': 'vue-jest',
5+
'.+\\.(css|styl|less|sass|scss|svg|png|jpg|ttf|woff|woff2)$':
6+
'jest-transform-stub',
7+
'^.+\\.jsx?$': 'babel-jest'
8+
},
9+
moduleNameMapper: {
10+
'^@/(.*)$': '<rootDir>/src/$1'
11+
},
12+
snapshotSerializers: ['jest-serializer-vue'],
13+
testMatch: [
14+
'**/tests/unit/**/*.spec.(js|jsx|ts|tsx)|**/__tests__/*.(js|jsx|ts|tsx)'
15+
],
16+
testURL: 'http://localhost/'
1717
};

package.json

+7-7
Original file line numberDiff line numberDiff line change
@@ -19,22 +19,22 @@
1919
"vue-router": "^3.1.2"
2020
},
2121
"devDependencies": {
22-
"@vue/cli": "^3.7.0",
23-
"@vue/cli-plugin-babel": "^3.4.0",
24-
"@vue/cli-plugin-eslint": "^3.8.0",
25-
"@vue/cli-plugin-unit-jest": "^3.8.0",
26-
"@vue/cli-service": "^3.10.0",
22+
"@vue/cli": "^4.0.0",
23+
"@vue/cli-plugin-babel": "^4.0.0",
24+
"@vue/cli-plugin-eslint": "^4.0.0",
25+
"@vue/cli-plugin-unit-jest": "^4.0.0",
26+
"@vue/cli-service": "^4.0.0",
2727
"@vue/eslint-config-prettier": "^4.0.1",
2828
"@vue/test-utils": "^1.0.0-beta.20",
2929
"babel-core": "7.0.0-bridge.0",
3030
"babel-eslint": "^10.0.1",
31-
"babel-jest": "^23.6.0",
31+
"babel-jest": "^24.9.0",
3232
"eslint": "^5.16.0",
3333
"eslint-plugin-vue": "^5.2.3",
3434
"fibers": "^4.0.1",
3535
"node-sass": "^4.12.0",
3636
"sass": "^1.23.0",
37-
"sass-loader": "^7.1.0",
37+
"sass-loader": "^8.0.0",
3838
"shipit-cli": "^4.2.0",
3939
"shipit-deploy": "^5.0.0",
4040
"vue-template-compiler": "^2.6.10"

postcss.config.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
module.exports = {
2-
plugins: {
3-
autoprefixer: {}
4-
}
2+
plugins: {
3+
autoprefixer: {}
4+
}
55
};

shipitfile.js

+23-7
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,34 @@ module.exports = shipit => {
55
const date = new Date();
66
await shipit.copyToRemote(
77
'dist/',
8-
'/srv/uitslagen.poweredbyiris.nl/releases/' + date.getFullYear() + date.getMonth() + date.getDate() + date.getHours() + date.getMinutes() + date.getSeconds()
8+
'/srv/uitslagen.poweredbyiris.nl/releases/' +
9+
date.getFullYear() +
10+
date.getMonth() +
11+
date.getDate() +
12+
date.getHours() +
13+
date.getMinutes() +
14+
date.getSeconds()
15+
);
16+
await shipit.remote(
17+
'ln -snf releases/' +
18+
date.getFullYear() +
19+
date.getMonth() +
20+
date.getDate() +
21+
date.getHours() +
22+
date.getMinutes() +
23+
date.getSeconds() +
24+
' /srv/uitslagen.poweredbyiris.nl/current'
925
);
10-
await shipit.remote('ln -snf releases/' + date.getFullYear() + date.getMonth() + date.getDate() + date.getHours() + date.getMinutes() + date.getSeconds() + ' /srv/uitslagen.poweredbyiris.nl/current');
1126
});
1227

1328
shipit.initConfig({
1429
default: {
1530
deployTo: '/srv/uitslagen.poweredbyiris.nl',
16-
repositoryUrl: 'https://github.com/Proteus-Eretes/hoesnelwasik_frontend.git',
31+
repositoryUrl:
32+
'https://github.com/Proteus-Eretes/hoesnelwasik_frontend.git'
1733
},
1834
live: {
19-
servers: '[email protected]',
20-
},
21-
})
22-
}
35+
servers: '[email protected]'
36+
}
37+
});
38+
};

src/App.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<template>
22
<div id="app">
3-
<router-view/>
3+
<router-view />
44
</div>
55
</template>
66

src/Helpers/ResultStatus.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,4 +59,4 @@ export class ResultStatus {
5959
if (ResultStatus.isDidNotFinish(status)) return 'DNF';
6060
return '';
6161
}
62-
}
62+
}

src/Helpers/uniqBy.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ export default (data, key) => {
77
seen.push(item[key]);
88
return true;
99
});
10-
};
10+
};

src/Services/Crews.js

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
import {Regatta} from "./Regatta";
2-
1+
import { Regatta } from './Regatta';
32

43
export class Crews extends Regatta {
54
/**

src/Services/Regatta.js

-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import { Service } from './Service';
22
import moment from 'moment';
33

44
export class Regatta extends Service {
5-
65
/**
76
* {@inheritDoc}
87
* @param {string} baseUrl

src/Views/Home.vue

+9-13
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,18 @@
11
<template>
2-
<div class="home">
3-
<img alt="Vue logo" src="../assets/logo.png" />
4-
<team-popup>
5-
6-
</team-popup>
7-
</div>
2+
<div class="home">
3+
<img alt="Vue logo" src="../assets/logo.png" />
4+
<team-popup> </team-popup>
5+
</div>
86
</template>
97

108
<script>
119
// @ is an alias to /src
12-
import FinishTime from "@/components/Time/FinishTime.vue";
13-
import TeamPopup from "../components/Team/TeamPopup";
10+
import TeamPopup from '../components/Team/TeamPopup';
1411
1512
export default {
16-
name: "home",
17-
components: {
18-
TeamPopup,
19-
FinishTime
20-
}
13+
name: 'home',
14+
components: {
15+
TeamPopup
16+
}
2117
};
2218
</script>

src/Views/IframeCrewDrawView.vue

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77

88
<script>
99
import NavBar from '@/components/Navigation/NavBar';
10-
import DrawOverview from "@/components/Crews/DrawOverview";
11-
import {Crews} from "@/Services/Crews";
12-
import {sendPageView} from "./analytics";
10+
import DrawOverview from '@/components/Crews/DrawOverview';
11+
import { Crews } from '@/Services/Crews';
12+
import { sendPageView } from './analytics';
1313
1414
export default {
1515
name: 'IframeCrewDrawView',

src/Views/IframeCrewResultsView.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
import NavBar from '@/components/Navigation/NavBar';
1010
import { Crews } from '@/Services/Crews';
1111
import ResultOverview from '../components/Crews/ResultOverview';
12-
import {sendPageView} from "./analytics";
12+
import { sendPageView } from './analytics';
1313
1414
export default {
1515
name: 'IframeCrewResultsView',

src/Views/IframeCrewSearchView.vue

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
<script>
99
import NavBar from '@/components/Navigation/NavBar';
1010
import { Crews } from '@/Services/Crews';
11-
import SearchOverview from "../components/Crews/SearchOverview";
12-
import {sendPageView} from "./analytics";
11+
import SearchOverview from '../components/Crews/SearchOverview';
12+
import { sendPageView } from './analytics';
1313
1414
export default {
1515
name: 'IframeCrewSearchView',

src/Views/IframeView.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
import NavBar from '@/components/Navigation/NavBar';
1414
import RegattaOverview from '@/components/Regatta/RegattaOverview';
1515
import { Regatta } from '../Services/Regatta';
16-
import {sendPageView} from "./analytics";
16+
import { sendPageView } from './analytics';
1717
1818
export default {
1919
name: 'iframe-view',

src/components/Blocks/BlockCard.vue

+6-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
<script>
2424
import moment from 'moment';
25-
import {openPage} from "../../Helpers/Routing";
25+
import { openPage } from '../../Helpers/Routing';
2626
2727
export default {
2828
name: 'BlockCard',
@@ -54,7 +54,11 @@ export default {
5454
},
5555
methods: {
5656
removeSecondsFields(starttime) {
57-
if (starttime === null || starttime === this.block[0].starttime || this.isNumber(starttime)) {
57+
if (
58+
starttime === null ||
59+
starttime === this.block[0].starttime ||
60+
this.isNumber(starttime)
61+
) {
5862
return this.removeSeconds(this.block[0].starttime);
5963
}
6064
return moment(starttime).format('H:mm');

src/components/Clubs/ClubsOverview.vue

+10-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
<template>
22
<div v-if="clubs">
3-
<b-table class="clickable" hover striped head-variant="dark" :items="clubs" :fields="fields" @row-clicked="rowClicked" >
3+
<b-table
4+
class="clickable"
5+
hover
6+
striped
7+
head-variant="dark"
8+
:items="clubs"
9+
:fields="fields"
10+
@row-clicked="rowClicked"
11+
>
412
<template slot="OarImage" slot-scope="row">
513
<OarImage :club="row.item.clubshort"></OarImage>
614
</template>
@@ -11,7 +19,7 @@
1119
<script>
1220
// @ is an alias to /src
1321
import OarImage from '@/components/Clubs/OarImage.vue';
14-
import {openClub} from "../../Helpers/Routing";
22+
import { openClub } from '../../Helpers/Routing';
1523
1624
export default {
1725
name: 'ClubsOverview',

src/components/Crews/DrawOverview.vue

+8-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,13 @@
77
</div>
88
<b-row>
99
<div class="table-responsive">
10-
<b-table hover :items="crews" :fields="fields" thead-class="thead-dark" @row-clicked="openTeamDialog">
10+
<b-table
11+
hover
12+
:items="crews"
13+
:fields="fields"
14+
thead-class="thead-dark"
15+
@row-clicked="openTeamDialog"
16+
>
1117
<template slot="OarImage" slot-scope="row">
1218
<OarImage :club="row.item.clubnameshort"></OarImage>
1319
</template>
@@ -27,7 +33,7 @@
2733
<script>
2834
import OarImage from '@/components/Clubs/OarImage.vue';
2935
import TeamPopup from '@/components/Team/TeamPopup.vue';
30-
import ViewNavigationBar from "../Navigation/ViewNavigationBar";
36+
import ViewNavigationBar from '../Navigation/ViewNavigationBar';
3137
3238
export default {
3339
name: 'DrawOverview',

src/components/Crews/ResultOverview.vue

+5-6
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@
2828
</template>
2929
<template slot="FinishTime" slot-scope="row">
3030
<FinalTime
31-
:time= "getFinishTime(row.item.times[0].times)"
31+
:time="getFinishTime(row.item.times[0].times)"
3232
:bonus-seconds="row.item.times[0].bonussecond"
3333
:status="row.item.times[0].status"
3434
></FinalTime>
3535
</template>
3636
<template slot="FinishTimeSmall" slot-scope="row">
3737
<FinalTime
38-
:time= "getFinishTime(row.item.times[0].times)"
38+
:time="getFinishTime(row.item.times[0].times)"
3939
:bonus-seconds="row.item.times[0].bonussecond"
4040
:status="row.item.times[0].status"
4141
></FinalTime>
@@ -54,8 +54,8 @@ import OarImage from '@/components/Clubs/OarImage.vue';
5454
import TeamPopup from '@/components/Team/TeamPopup.vue';
5555
import FinalTime from '../Time/FinalTime';
5656
import ViewNavigationBar from '../Navigation/ViewNavigationBar';
57-
import {getFinishTime, getSplash} from "../Time/Time";
58-
import {highLightWinner} from "./highLightWinner";
57+
import { getFinishTime, getSplash } from '../Time/Time';
58+
import { highLightWinner } from './highLightWinner';
5959
import findClockingLocations from './findClockingLocations';
6060
6161
export default {
@@ -81,8 +81,7 @@ export default {
8181
},
8282
getFinishTime,
8383
highLightWinner,
84-
getSplash,
85-
84+
getSplash
8685
},
8786
computed: {
8887
fieldName() {

0 commit comments

Comments
 (0)