This is an Electron application developed to generate GeoJSON annotation data for use in the LIMMMA platform.
- Node.js (v18 or higher recommended)
- npm (comes with Node.js)
-
Clone the repository:
git clone <repository-url> cd offLIMMMA
-
Install dependencies:
npm install
Run the application in development mode with hot-reloading:
npm run devBuild and run the production version:
npm startYou can specify an initial map view using a bounding box parameter with support for different coordinate systems:
# Format: --bbox=minX,minY,maxX,maxY[,zoom] --epsg=EPSG_CODE
# Using WGS84 (default, longitude/latitude):
npm start -- --bbox=106.8,-6.2,106.9,-6.1,12
# Using a different EPSG code (e.g., UTM Zone 48N):
npm start -- --bbox=500000,6900000,600000,7000000 --epsg=32648
# With the packaged Windows executable:
OffLIMMMA\ 1.0.0.exe --bbox=106.8,-6.2,106.9,-6.1,12 --epsg=4326
# Or from command line/PowerShell:
.\release\OffLIMMMA\ 1.0.0.exe --bbox=106.8,-6.2,106.9,-6.1,12The bounding box parameters:
minX: Minimum X coordinate (west/east depending on projection)minY: Minimum Y coordinate (south/north depending on projection)maxX: Maximum X coordinatemaxY: Maximum Y coordinatezoom: Optional zoom level (if omitted, the map will auto-fit to the bounding box)--epsg: EPSG code for the coordinate system (default: 4326 for WGS84)
Common EPSG codes:
4326: WGS84 (longitude/latitude) - default3857: Web Mercator (used internally by the map)32648: UTM Zone 48N (and other UTM zones)- Many other coordinate systems supported by OpenLayers
Create standalone executables for distribution:
# Windows
npm run package:win
# macOS
npm run package:mac
# Linux
npm run package:linux
# Current platform
npm run packageBuilt packages will be available in the release/ directory.
You can bake a default bounding box into the packaged executable:
# Windows with default bounding box
npm run package:win:bbox -- --bbox=106.8,-6.2,106.9,-6.1,12 --epsg=4326
# macOS with default bounding box
npm run package:mac:bbox -- --bbox=106.8,-6.2,106.9,-6.1,12
# Linux with default bounding box
npm run package:linux:bbox -- --bbox=106.8,-6.2,106.9,-6.1,12 --epsg=4326Note: The -- is required to pass arguments to the script. Without it, npm will try to interpret them as npm config options.
When the packaged executable runs, it will automatically load to the specified bounding box. Users can still override this by passing --bbox arguments when launching the executable.
MIT