File tree Expand file tree Collapse file tree 7 files changed +37
-7
lines changed Expand file tree Collapse file tree 7 files changed +37
-7
lines changed Original file line number Diff line number Diff line change @@ -2,3 +2,4 @@ node_modules
22package-lock.json
33coverage
44* .tgz
5+ /types
Original file line number Diff line number Diff line change 1818 "url" : " git+https://github.com/hyparam/geoparquet.git"
1919 },
2020 "dependencies" : {
21- "hyparquet" : " 1.17.2 "
21+ "hyparquet" : " 1.17.3 "
2222 },
2323 "devDependencies" : {
2424 "@rollup/plugin-node-resolve" : " 16.0.1" ,
3434 "vitest" : " 3.2.4"
3535 },
3636 "files" : [
37- " src"
37+ " src" ,
38+ " types"
3839 ],
40+ "type" : " module" ,
41+ "types" : " types/index.d.ts" ,
3942 "main" : " src/index.js" ,
43+ "exports" : {
44+ "browser" : {
45+ "types" : " ./types/index.d.ts" ,
46+ "import" : " ./src/index.js"
47+ },
48+ "default" : {
49+ "types" : " ./types/node.d.ts" ,
50+ "import" : " ./src/node.js"
51+ }
52+ },
4053 "scripts" : {
4154 "build" : " rollup -c" ,
55+ "build:types" : " tsc -p ./tsconfig.lib.json" ,
4256 "coverage" : " vitest run --coverage --coverage.include=src" ,
4357 "lint" : " eslint" ,
58+ "prepare" : " npm run build:types" ,
4459 "start" : " http-server -a localhost" ,
4560 "test" : " vitest run"
46- },
47- "type" : " module"
61+ }
4862}
Original file line number Diff line number Diff line change 1- export { asyncBufferFromFile , asyncBufferFromUrl } from 'hyparquet'
1+ export { asyncBufferFromUrl } from 'hyparquet'
22export { toGeoJson } from './toGeoJson.js'
33export { decodeWKB } from './wkb.js'
Original file line number Diff line number Diff line change 1+ export { asyncBufferFromFile } from 'hyparquet'
2+ export * from './index.js'
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ import { decodeWKB } from './wkb.js'
77 * An AsyncBuffer is a buffer-like object that can be read asynchronously.
88 *
99 * @import { AsyncBuffer, Compressors } from 'hyparquet'
10- * @import { Feature, GeoJSON } from './geojson.js'
10+ * @import { Feature, GeoJSON } from '../src /geojson.js'
1111 * @param {Object } options
1212 * @param {AsyncBuffer } options.file
1313 * @param {Compressors } [options.compressors]
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ const geometryTypeCompoundSurface = 24
2727/**
2828 * WKB (Well Known Binary) decoder for geometry objects.
2929 *
30- * @import { Geometry } from './geojson.js'
30+ * @import { Geometry } from '../src /geojson.js'
3131 * @param {Uint8Array } wkb
3232 * @returns {Geometry } GeoJSON geometry object
3333 */
Original file line number Diff line number Diff line change 1+ {
2+ "extends" : " ./tsconfig.json" ,
3+ "compilerOptions" : {
4+ "noEmit" : false ,
5+ "declaration" : true ,
6+ "emitDeclarationOnly" : true ,
7+ "outDir" : " types" ,
8+ "lib" : [" esnext" , " dom" ],
9+ "declarationMap" : true
10+ },
11+ "include" : [" src" ]
12+ }
13+
You can’t perform that action at this time.
0 commit comments