Migrate style
migrate_styleConverts outdated MapLibre styles to the current specification: version 7 to 8, legacy functions and filters to expressions. Accepts a file path to update in place or returns migrated JSON.
Instructions
Migrates an old style to the current MapLibre Style Specification, the same way as gl-style-migrate: version 7 styles become version 8, and legacy functions and filters become expressions. A style given as a file path is migrated in place, otherwise the migrated JSON is returned.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | URL of a style JSON document. | |
| path | No | Path to a style JSON file, relative to the directory the server runs in. | |
| style | No | The style as a JSON object. |