|
4 | 4 | "description": "OpenLayers Cesium integration and plugin library", |
5 | 5 | "scripts": { |
6 | 6 | "test": "node --enable-source-maps --import @swc-node/register/esm-register --test src/olcs/*.test.ts", |
7 | | - "build-examples": "rm -rf dist; parcel build; mkdir -p dist/examples/node_modules/ol; mkdir -p dist/examples/node_modules/cesium/Build/; cp examples/inject_ol_cesium.js dist/examples/; cp node_modules/ol/ol.css dist/examples/node_modules/ol/; cp -R node_modules/cesium/Build/CesiumUnminified node_modules/cesium/Build/Cesium dist/examples/node_modules/cesium/Build/; cp -R examples/data dist/examples/", |
| 7 | + "build-examples": "rm -rf dist; parcel build --dist-dir dist/examples && npm run copy-static-dist", |
8 | 8 | "prepare": "tsc --pretty && node buildtools/fix_paths_recast.js; npm run doc", |
9 | 9 | "typecheck": "tsc --pretty --noEmit", |
10 | 10 | "lint": "eslint src buildtools examples", |
11 | 11 | "checks": "npm run lint && npm run typecheck", |
12 | 12 | "doc": "typedoc --name ol-cesium --excludeExternals --out apidoc --entryPoints src/olcs.ts --tsconfig ./tsconfig.json", |
13 | | - "start": "parcel serve --no-autoinstall --target examples", |
| 13 | + "copy-static-dist": "mkdir -p dist/examples/node_modules/ol; mkdir -p dist/examples/node_modules/cesium/Build/; cp examples/inject_ol_cesium.js dist/examples/; cp node_modules/ol/ol.css dist/examples/node_modules/ol/; cp -R node_modules/cesium/Build/CesiumUnminified node_modules/cesium/Build/Cesium dist/examples/node_modules/cesium/Build/; cp -R examples/data dist/examples/", |
| 14 | + "prestart": "rm -rf dist; npm run copy-static-dist", |
| 15 | + "start": "parcel serve ./examples/index.html --dist-dir dist/examples --no-autoinstall & tsc --watch", |
14 | 16 | "serve-built-examples": "python3 -m http.server --directory dist 12345" |
15 | 17 | }, |
16 | 18 | "targets": { |
17 | 19 | "examples": { |
18 | 20 | "source": "./examples/index.html", |
19 | | - "distDir": "dist/examples/", |
20 | 21 | "context": "browser", |
21 | 22 | "publicUrl": "./", |
22 | 23 | "optimize": true, |
|
0 commit comments