File tree 3 files changed +7
-11
lines changed
3 files changed +7
-11
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ esbuild.build({
5
5
entryPoints : [ "./src/index.tsx" ] ,
6
6
bundle : true ,
7
7
minify : true ,
8
- target : [ "es2020 " ] ,
8
+ target : [ "es2022 " ] ,
9
9
outdir : "lonboard/static/" ,
10
10
format : "esm" ,
11
11
// Ref https://github.com/manzt/anywidget/issues/369#issuecomment-1792376003
Original file line number Diff line number Diff line change 1
1
import * as React from "react" ;
2
2
import { useState , useEffect } from "react" ;
3
3
import { createRender , useModelState , useModel } from "@anywidget/react" ;
4
- import type { Initialize , InitializeProps , Render } from "@anywidget/types" ;
4
+ import type { Initialize , Render } from "@anywidget/types" ;
5
5
import Map from "react-map-gl/maplibre" ;
6
6
import DeckGL from "@deck.gl/react/typed" ;
7
7
import type { Layer } from "@deck.gl/core/typed" ;
@@ -12,6 +12,8 @@ import { getTooltip } from "./tooltip/index.js";
12
12
import { loadChildModels } from "./util.js" ;
13
13
import { v4 as uuidv4 } from "uuid" ;
14
14
15
+ await initParquetWasm ( ) ;
16
+
15
17
const DEFAULT_INITIAL_VIEW_STATE = {
16
18
latitude : 10 ,
17
19
longitude : 0 ,
@@ -139,13 +141,8 @@ function App() {
139
141
) ;
140
142
}
141
143
142
- async function initialize ( { } : InitializeProps ) {
143
- await initParquetWasm ( ) ;
144
- }
145
-
146
- const module : { render : Render ; initialize : Initialize } = {
144
+ const module : { render : Render ; initialize ?: Initialize } = {
147
145
render : createRender ( App ) ,
148
- initialize,
149
146
} ;
150
147
151
148
export default module ;
Original file line number Diff line number Diff line change 2
2
"include" : [" src/**/*" ],
3
3
"exclude" : [" node_modules" ],
4
4
"compilerOptions" : {
5
- // Note: setting these two to NodeNext this breaks typing for apache-arrow
6
5
"moduleResolution" : " node" ,
7
- // "module": "NodeNext ",
6
+ "module" : " ES2022 " ,
8
7
"outDir" : " ./dist" ,
9
8
"allowJs" : true ,
10
- "target" : " ES2020 " ,
9
+ "target" : " ES2022 " ,
11
10
"declaration" : true ,
12
11
"noEmit" : false ,
13
12
"noEmitOnError" : false ,
You can’t perform that action at this time.
0 commit comments