Skip to content

Commit deb8b6e

Browse files
Merge pull request #505 from phatj/fix/create-element-alias
fix: make createElement compatible with 1.0.0 of @vue/composition-api
2 parents 79aa3a8 + b052864 commit deb8b6e

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

src/FeathersVuexPagination.ts

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,20 @@
1-
import { createElement, computed, watch } from '@vue/composition-api'
1+
import {
2+
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
3+
// @ts-ignore
4+
createElement as baseCreateElement,
5+
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
6+
// @ts-ignore
7+
h,
8+
computed,
9+
watch
10+
} from '@vue/composition-api'
11+
import { CreateElement } from 'vue'
12+
13+
/**
14+
* Allow for usage with newer (^1.0.0) @vue/composition-api releases
15+
* See: https://github.com/feathersjs-ecosystem/feathers-vuex/issues/504
16+
*/
17+
const createElement = (baseCreateElement || h) as CreateElement
218

319
export default {
420
name: 'FeathersVuexPagination',

0 commit comments

Comments
 (0)