Skip to content

Commit c88ea4a

Browse files
committed
feature: Expose OLCesiumOptions
Downstream projects find it helpful to be able to reuse the type definition of the constructor options for the main OLCesium object.
1 parent 7b31dc3 commit c88ea4a

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/olcs.ts

+2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import OLCesium from './olcs/OLCesium.js';
22
export default OLCesium;
33

4+
export type {OLCesiumOptions} from './olcs/OLCesium.js';
5+
46
export {default as AbstractSynchronizer} from './olcs/AbstractSynchronizer.js';
57
export {default as RasterSynchronizer} from './olcs/RasterSynchronizer.js';
68
export {default as VectorSynchronizer} from './olcs/VectorSynchronizer.js';

src/olcs/OLCesium.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -61,13 +61,13 @@ type SceneOptions = {
6161
msaaSamples?: number;
6262
}
6363

64-
type OLCesiumOptions = {
64+
export type OLCesiumOptions = {
6565
map: Map,
6666
time?: () => JulianDate,
6767
target?: Element | string,
6868
createSynchronizers?: (map: Map, scene: Scene, dataSourceCollection: DataSourceCollection) => AbstractSynchronizer<ImageryLayer | VectorLayerCounterpart>[],
6969
stopOpenLayersEventsPropagation?: boolean,
70-
sceneOptions?: SceneOptions
70+
sceneOptions?: Omit<SceneOptions, 'canvas'|'scene3DOnly'>
7171
}
7272

7373
// FIXME: remove this when all the synchronizers are migrated to typescript.

0 commit comments

Comments
 (0)