Skip to content

Commit

Permalink
chore: update to typescript 3.3
Browse files Browse the repository at this point in the history
  • Loading branch information
KaelWD committed Feb 11, 2019
1 parent fb348f1 commit a0d6fef
Show file tree
Hide file tree
Showing 9 changed files with 61 additions and 50 deletions.
16 changes: 8 additions & 8 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module.exports = {
root: true,
parserOptions: {
parser: 'eslint-plugin-typescript/parser',
parser: '@typescript-eslint/parser',
ecmaVersion: 2017,
sourceType: 'module'
},
Expand All @@ -15,7 +15,7 @@ module.exports = {
es6: true
},
plugins: [
'typescript'
'@typescript-eslint'
],
rules: {
// allow paren-less arrow functions
Expand Down Expand Up @@ -95,21 +95,21 @@ module.exports = {
// https://github.com/eslint/typescript-eslint-parser/issues/457
// enabled in tslint instead
'no-unused-vars': 'off',
// 'typescript/no-unused-vars': 'error',
// '@typescript-eslint/no-unused-vars': 'error',

'no-redeclare': 'error',
'typescript/prefer-namespace-keyword': 'error',
'typescript/adjacent-overload-signatures': 'error',
'typescript/member-delimiter-style': ['error', {
'@typescript-eslint/prefer-namespace-keyword': 'error',
'@typescript-eslint/adjacent-overload-signatures': 'error',
'@typescript-eslint/member-delimiter-style': ['error', {
multiline: {
delimiter: 'none'
},
singleline: {
delimiter: 'comma'
}
}],
'typescript/member-ordering': 'error',
'typescript/type-annotation-spacing': 'error'
'@typescript-eslint/member-ordering': 'error',
'@typescript-eslint/type-annotation-spacing': 'error'
}
}
]
Expand Down
9 changes: 6 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"private": true,
"workspaces": [ "packages/*" ],
"workspaces": [
"packages/*"
],
"husky": {
"hooks": {
"prepare-commit-msg": "node scripts/prepare-commit-message.js",
Expand All @@ -17,14 +19,15 @@
"postversion": "node scripts/post-release-merge.js"
},
"devDependencies": {
"@typescript-eslint/eslint-plugin": "^1.3.0",
"@typescript-eslint/parser": "^1.3.0",
"eslint": "^5.13.0",
"eslint-config-standard": "^12.0.0",
"eslint-plugin-import": "^2.16.0",
"eslint-plugin-local-rules": "^0.1.0",
"eslint-plugin-node": "^8.0.1",
"eslint-plugin-promise": "^4.0.1",
"eslint-plugin-standard": "^4.0.0",
"eslint-plugin-typescript": "^1.0.0-rc.3",
"eslint-plugin-vue": "^5.1.0",
"husky": "^1.3.1",
"inquirer": "^6.2.2",
Expand All @@ -38,7 +41,7 @@
"shelljs": "^0.8.2",
"ts-jest": "^21.2.1",
"tslint": "^5.12.1",
"typescript": "^3.1.3",
"typescript": "^3.3.3",
"typestrict": "^1.0.2",
"vue": "^2.6.4",
"vue-template-compiler": "^2.6.4"
Expand Down
2 changes: 1 addition & 1 deletion packages/vuetify/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
"stylus-loader": "^3.0.2",
"ts-loader": "^5.3.3",
"tslint": "^5.12.1",
"typescript": "^3.1.3",
"typescript": "^3.3.3",
"url-loader": "^1.1.2",
"vue-loader": "^15.6.2",
"vue-router": "^3.0.2",
Expand Down
2 changes: 1 addition & 1 deletion packages/vuetify/src/components/VCard/VCard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export default mixins(
}
},
styles (): object {
const style = {
const style: Dictionary<string> = {
...VSheet.options.computed.styles.call(this)
}

Expand Down
8 changes: 4 additions & 4 deletions packages/vuetify/src/components/VImg/VImg.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export default VResponsive.extend({
aspect: Number(this.aspectRatio || this.src.aspect || this.calculatedAspectRatio)
}
},
__cachedImage (): VNode | never[] {
__cachedImage (): VNode | [] {
if (!(this.normalisedSrc.src || this.normalisedSrc.lazySrc)) return []

const backgroundImage: string[] = []
Expand Down Expand Up @@ -205,9 +205,9 @@ export default VResponsive.extend({
render (h): VNode {
const node = VResponsive.options.render.call(this, h)

node.data.staticClass += ' v-image'
node.data!.staticClass += ' v-image'

node.data.attrs = {
node.data!.attrs = {
role: this.alt ? 'img' : undefined,
'aria-label': this.alt
}
Expand All @@ -217,7 +217,7 @@ export default VResponsive.extend({
this.__cachedImage,
this.__genPlaceholder(),
this.genContent()
]
] as VNode[]

return h(node.tag, node.data, node.children)
}
Expand Down
2 changes: 1 addition & 1 deletion packages/vuetify/src/components/VResponsive/VResponsive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export default mixins(Measurable).extend({
? { paddingBottom: (1 / this.computedAspectRatio) * 100 + '%' }
: undefined
},
__cachedSizer (): VNode | never[] {
__cachedSizer (): VNode | [] {
if (!this.aspectStyle) return []

return this.$createElement('div', {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,10 +98,10 @@ export default mixins<options &
},

methods: {
wheel (e: MouseWheelEvent) {
wheel (e: WheelEvent) {
e.preventDefault()

const delta = Math.sign(e.wheelDelta || 1)
const delta = Math.sign(-e.deltaY || 1)
let value = this.displayedValue
do {
value = value + delta
Expand Down
2 changes: 1 addition & 1 deletion packages/vuetify/src/mixins/overlayable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ export default Vue.extend<Vue & Toggleable & Stackable & options>().extend({
},
checkPath (e: WheelEvent) {
const path = e.path || this.composedPath(e)
const delta = e.deltaY || -e.wheelDelta
const delta = e.deltaY

if (e.type === 'keydown' && path[0] === document.body) {
const dialog = this.$refs.dialog
Expand Down
66 changes: 37 additions & 29 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -634,6 +634,32 @@
resolved "https://registry.yarnpkg.com/@types/node/-/node-10.12.0.tgz#ea6dcbddbc5b584c83f06c60e82736d8fbb0c235"
integrity sha512-3TUHC3jsBAB7qVRGxT6lWyYo2v96BMmD2PTcl47H25Lu7UXtFH/2qqmKiVrnel6Ne//0TFYf6uvNX+HW2FRkLQ==

"@typescript-eslint/eslint-plugin@^1.3.0":
version "1.3.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-1.3.0.tgz#e64c859a3eec10d96731eb5f72b5f48796a2f9ad"
integrity sha512-s+vjO9+PvYS2A6FnQC/imyEDOkrEKIzSpPf2OEGnkKqa5+1d0cuXgCi/oROtuBht2/u/iK22nrYcO/Ei4R8F/g==
dependencies:
"@typescript-eslint/parser" "1.3.0"
requireindex "^1.2.0"
tsutils "^3.7.0"

"@typescript-eslint/parser@1.3.0", "@typescript-eslint/parser@^1.3.0":
version "1.3.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-1.3.0.tgz#e61e795aa050351b7312a757e0864b6d90b84078"
integrity sha512-Q5cz9nyEQyRrtItRElvQXdNs0Xja1xvOdphDQR7N6MqUdi4juWVNxHKypdHQCx9OcEBev6pWHOda8lwg/2W9/g==
dependencies:
"@typescript-eslint/typescript-estree" "1.3.0"
eslint-scope "^4.0.0"
eslint-visitor-keys "^1.0.0"

"@typescript-eslint/typescript-estree@1.3.0":
version "1.3.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-1.3.0.tgz#1d1f36680e5c32c3af38c1180153f018152f65f9"
integrity sha512-h6UxHSmBUopFcxHg/eryrA+GwHMbh7PxotMbkq9p2f3nX60CKm5Zc0VN8krBD3IS5KqsK0iOz24VpEWrP+JZ2Q==
dependencies:
lodash.unescape "4.0.1"
semver "5.5.0"

"@vue/component-compiler-utils@^2.5.1":
version "2.5.2"
resolved "https://registry.yarnpkg.com/@vue/component-compiler-utils/-/component-compiler-utils-2.5.2.tgz#a8d57e773354ab10e4742c7d6a8dd86184d4d7be"
Expand Down Expand Up @@ -4453,14 +4479,6 @@ eslint-plugin-standard@^4.0.0:
resolved "https://registry.yarnpkg.com/eslint-plugin-standard/-/eslint-plugin-standard-4.0.0.tgz#f845b45109c99cd90e77796940a344546c8f6b5c"
integrity sha512-OwxJkR6TQiYMmt1EsNRMe5qG3GsbjlcOhbGUBY4LtavF9DsLaTcoR+j2Tdjqi23oUwKNUqX7qcn5fPStafMdlA==

eslint-plugin-typescript@^1.0.0-rc.3:
version "1.0.0-rc.3"
resolved "https://registry.yarnpkg.com/eslint-plugin-typescript/-/eslint-plugin-typescript-1.0.0-rc.3.tgz#aa5359248dc6172ee261bc6574b5b540573e9b67"
integrity sha512-urXH7sKqRkFLcDj6dP3tvQALfWIRGn8J8Kg9dYSoavXvy62FxfUv6JgjDAHQZudi9fSRQpEZA/LqdJXDOwKHPA==
dependencies:
requireindex "^1.2.0"
typescript-eslint-parser "21.0.2"

eslint-plugin-vue@^5.1.0:
version "5.1.0"
resolved "https://registry.yarnpkg.com/eslint-plugin-vue/-/eslint-plugin-vue-5.1.0.tgz#d0d373334be8140d698ec4e1fb83f09faa48081b"
Expand Down Expand Up @@ -11813,6 +11831,13 @@ tsutils@^2.27.2:
dependencies:
tslib "^1.8.1"

tsutils@^3.7.0:
version "3.8.0"
resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-3.8.0.tgz#7a3dbadc88e465596440622b65c04edc8e187ae5"
integrity sha512-XQdPhgcoTbCD8baXC38PQ0vpTZ8T3YrE+vR66YIj/xvDt1//8iAhafpIT/4DmvzzC1QFapEImERu48Pa01dIUA==
dependencies:
tslib "^1.8.1"

tty-browserify@0.0.0:
version "0.0.0"
resolved "https://registry.yarnpkg.com/tty-browserify/-/tty-browserify-0.0.0.tgz#a157ba402da24e9bf957f9aa69d524eed42901a6"
Expand Down Expand Up @@ -11850,27 +11875,10 @@ typedarray@^0.0.6:
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=

typescript-eslint-parser@21.0.2:
version "21.0.2"
resolved "https://registry.yarnpkg.com/typescript-eslint-parser/-/typescript-eslint-parser-21.0.2.tgz#270af10e4724528677fbcf34ea495284bec3a894"
integrity sha512-u+pj4RVJBr4eTzj0n5npoXD/oRthvfUCjSKndhNI714MG0mQq2DJw5WP7qmonRNIFgmZuvdDOH3BHm9iOjIAfg==
dependencies:
eslint-scope "^4.0.0"
eslint-visitor-keys "^1.0.0"
typescript-estree "5.3.0"

typescript-estree@5.3.0:
version "5.3.0"
resolved "https://registry.yarnpkg.com/typescript-estree/-/typescript-estree-5.3.0.tgz#fb6c977b5e21073eb16cbdc0338a7f752da99ff5"
integrity sha512-Vu0KmYdSCkpae+J48wsFC1ti19Hq3Wi/lODUaE+uesc3gzqhWbZ5itWbsjylLVbjNW4K41RqDzSfnaYNbmEiMQ==
dependencies:
lodash.unescape "4.0.1"
semver "5.5.0"

typescript@^3.1.3:
version "3.1.3"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.1.3.tgz#01b70247a6d3c2467f70c45795ef5ea18ce191d5"
integrity sha512-+81MUSyX+BaSo+u2RbozuQk/UWx6hfG0a5gHu4ANEM4sU96XbuIyAB+rWBW1u70c6a5QuZfuYICn3s2UjuHUpA==
typescript@^3.3.3:
version "3.3.3"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.3.3.tgz#f1657fc7daa27e1a8930758ace9ae8da31403221"
integrity sha512-Y21Xqe54TBVp+VDSNbuDYdGw0BpoR/Q6wo/+35M8PAU0vipahnyduJWirxxdxjsAkS7hue53x2zp8gz7F05u0A==

typestrict@^1.0.2:
version "1.0.2"
Expand Down

0 comments on commit a0d6fef

Please sign in to comment.