Skip to content

Commit 6733639

Browse files
authored
fix ts strict issue (#84)
1 parent 47d7a7f commit 6733639

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

src/picking.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ export function getPickingInfo(
2121
const recordBatchIdx: number = sourceLayer.props.recordBatchIdx;
2222
const batch = table.batches[recordBatchIdx];
2323
const row = batch.get(index);
24+
if (row === null) {
25+
return info;
26+
}
2427

2528
// @ts-expect-error hack: using private method to avoid recomputing via
2629
// batch lengths on each iteration

src/text-layer.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@ const ourDefaultProps: Pick<
131131
_validate: true,
132132
};
133133

134+
// @ts-expect-error Type error in merging default props with ours
134135
const defaultProps: DefaultProps<GeoArrowTextLayerProps> = {
135136
..._defaultProps,
136137
...ourDefaultProps,

src/types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import type { Accessor, Color, PickingInfo } from "@deck.gl/core/typed";
22
import * as arrow from "apache-arrow";
33

44
export type GeoArrowPickingInfo = PickingInfo & {
5-
object: arrow.StructRowProxy;
5+
object?: arrow.StructRowProxy;
66
};
77

88
export type FloatAccessor =

0 commit comments

Comments
 (0)