Skip to content

Commit 729a069

Browse files
authored
Fixed maximum call stack size error on CGrid.vue (#213)
1 parent 53e9ff2 commit 729a069

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

packages/vue-cheetah-grid/lib/CGrid.vue

+5-2
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,18 @@
2626
import { cheetahGrid, gridUpdateWatcher, extend } from './c-grid/utils'
2727
import { slotsToHeaderOptions, slotsToHeaderProps } from './c-grid/header-utils'
2828
29+
const primitives = {
30+
function: true, string: true, number: true, boolean: true, undefined: true, bigint: true, symbol: true
31+
}
2932
function deepObjectEquals (a, b) {
3033
if (a === b) {
3134
return true
3235
}
33-
if (typeof a !== typeof b ||
36+
if (typeof a !== typeof b || a == null || b == null ||
3437
a.constructor !== b.constructor) {
3538
return false
3639
}
37-
if (typeof a === 'function') {
40+
if (primitives[typeof a]) {
3841
return false
3942
}
4043
const aKeys = Object.keys(a).sort()

packages/vue-cheetah-grid/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-cheetah-grid",
3-
"version": "0.19.1",
3+
"version": "0.19.2",
44
"description": "Cheetah Grid for Vue.js",
55
"main": "dist/vueCheetahGrid.js",
66
"files": [

0 commit comments

Comments
 (0)