{"id":23185977,"url":"https://github.com/geostyler/geostyler-sld-parser","last_synced_at":"2026-01-30T11:22:58.152Z","repository":{"id":37612002,"uuid":"133524374","full_name":"geostyler/geostyler-sld-parser","owner":"geostyler","description":"GeoStyler-Style-Parser implementation for SLD","archived":false,"fork":false,"pushed_at":"2025-05-05T23:40:31.000Z","size":5561,"stargazers_count":55,"open_issues_count":28,"forks_count":36,"subscribers_count":19,"default_branch":"main","last_synced_at":"2025-05-06T00:34:19.977Z","etag":null,"topics":["geostyler","hacktoberfest","sld"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/geostyler.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"open_collective":"geostyler"}},"created_at":"2018-05-15T13:59:08.000Z","updated_at":"2025-04-08T11:23:58.000Z","dependencies_parsed_at":"2023-09-26T17:41:49.343Z","dependency_job_id":"e12a45a1-c678-46f9-9732-7b87a201b004","html_url":"https://github.com/geostyler/geostyler-sld-parser","commit_stats":{"total_commits":591,"total_committers":20,"mean_commits":29.55,"dds":0.7360406091370558,"last_synced_commit":"4187fa5d7cf5d6d350a041ae141244ab00c1763f"},"previous_names":["terrestris/geostyler-sld-parser"],"tags_count":74,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geostyler%2Fgeostyler-sld-parser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geostyler%2Fgeostyler-sld-parser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geostyler%2Fgeostyler-sld-parser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geostyler%2Fgeostyler-sld-parser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/geostyler","download_url":"https://codeload.github.com/geostyler/geostyler-sld-parser/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254564127,"owners_count":22092122,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["geostyler","hacktoberfest","sld"],"created_at":"2024-12-18T10:13:51.065Z","updated_at":"2026-01-30T11:22:58.145Z","avatar_url":"https://github.com/geostyler.png","language":"TypeScript","funding_links":["https://opencollective.com/geostyler"],"categories":[],"sub_categories":[],"readme":"# geostyler-sld-parser\n\n[![Coverage Status](https://coveralls.io/repos/github/geostyler/geostyler-sld-parser/badge.svg?branch=main)](https://coveralls.io/github/geostyler/geostyler-sld-parser?branch=main)\n[![License](https://img.shields.io/github/license/geostyler/geostyler-sld-parser)](https://github.com/geostyler/geostyler-sld-parser/blob/main/LICENSE)\n[![npm version](https://badge.fury.io/js/geostyler-sld-parser.svg)](https://www.npmjs.com/package/geostyler-sld-parser)\n\n[GeoStyler](https://github.com/terrestris/geostyler/) Style Parser implementation for Styled Layer Descriptor (SLD)\n\n## :rocket: GeoStyler Code Sprint 2025\n\nWe are happy to announce the next GeoStyler Code Sprint from **02.-06.06.2025** in Switzerland. Be part of it! More infos on https://geostyler.org/.\n\n### How to use\n\nES6:\n```js\nimport SLDParser from 'geostyler-sld-parser';\nimport { Style } from 'geostyler-style';\n\nconst pointSimplePoint = {\n  name: 'My Style',\n  rules: [\n    {\n      name: 'My Rule',\n      symbolizers: [\n        {\n          kind: 'Mark',\n          wellKnownName: 'circle',\n          color: '#FF0000',\n          radius: 6\n        }\n      ]\n    }\n  ]\n};\n\nconst parser = new SLDParser();\n\nparser\n  .writeStyle(pointSimplePoint)\n  .then(({output: sld}) =\u003e console.log(sld))\n  .catch(error =\u003e console.log(error));\n\n\n// Read style from string\nlet sldString = '\u003c?xml version=\"1.0\" encoding=\"UTF-8\"?\u003e\u003csld:StyledLayerDescriptor xmlns=\"http://www.opengis.net/sld\" xmlns:sld=\"http://www.opengis.net/sld\" xmlns:gml=\"http://www.opengis.net/gml\" xmlns:ogc=\"http://www.opengis.net/ogc\" version=\"1.0.0\"\u003e \u003csld:NamedLayer\u003e \u003csld:Name\u003eDefault Styler\u003c/sld:Name\u003e \u003csld:UserStyle\u003e \u003csld:Name\u003eDefault Styler\u003c/sld:Name\u003e \u003csld:Title\u003eGravel_Program_2016\u003c/sld:Title\u003e \u003csld:FeatureTypeStyle\u003e \u003csld:Name\u003ename\u003c/sld:Name\u003e \u003csld:Rule\u003e \u003csld:MinScaleDenominator\u003e1.0\u003c/sld:MinScaleDenominator\u003e \u003csld:MaxScaleDenominator\u003e1.0E7\u003c/sld:MaxScaleDenominator\u003e \u003csld:LineSymbolizer\u003e \u003csld:Stroke\u003e \u003csld:CssParameter name=\"stroke\"\u003e#8000FF\u003c/sld:CssParameter\u003e \u003csld:CssParameter name=\"stroke-width\"\u003e3.000\u003c/sld:CssParameter\u003e \u003c/sld:Stroke\u003e \u003c/sld:LineSymbolizer\u003e \u003c/sld:Rule\u003e \u003c/sld:FeatureTypeStyle\u003e \u003c/sld:UserStyle\u003e \u003c/sld:NamedLayer\u003e \u003c/sld:StyledLayerDescriptor\u003e';\n\nparser\n  .readStyle(sldString)\n  .then(({output: sldObject}) =\u003e console.log(sldObject))\n  .catch(error =\u003e console.log(error));\n\n```\n\nBrowser:\n\n```js\nconst pointSimplePoint = {\n  name: \"My Style\",\n  rules: [\n    {\n      name: \"My Rule\",\n      symbolizers: [\n        {\n          kind: \"Mark\",\n          wellKnownName: \"Circle\",\n          color: \"#FF0000\",\n          radius: 6\n        }\n      ]\n    }\n  ]\n};\nvar parser = new GeoStylerSLDParser.SldStyleParser();\nparser\n  .writeStyle(pointSimplePoint)\n  .then(({output: sld}) =\u003e console.log(sld))\n  .catch(error =\u003e console.log(error));\n\n// Read style from string\nvar sldString = '\u003c?xml version=\"1.0\" encoding=\"UTF-8\"?\u003e\u003csld:StyledLayerDescriptor xmlns=\"http://www.opengis.net/sld\" xmlns:sld=\"http://www.opengis.net/sld\" xmlns:gml=\"http://www.opengis.net/gml\" xmlns:ogc=\"http://www.opengis.net/ogc\" version=\"1.0.0\"\u003e \u003csld:NamedLayer\u003e \u003csld:Name\u003eDefault Styler\u003c/sld:Name\u003e \u003csld:UserStyle\u003e \u003csld:Name\u003eDefault Styler\u003c/sld:Name\u003e \u003csld:Title\u003eGravel_Program_2016\u003c/sld:Title\u003e \u003csld:FeatureTypeStyle\u003e \u003csld:Name\u003ename\u003c/sld:Name\u003e \u003csld:Rule\u003e \u003csld:MinScaleDenominator\u003e1.0\u003c/sld:MinScaleDenominator\u003e \u003csld:MaxScaleDenominator\u003e1.0E7\u003c/sld:MaxScaleDenominator\u003e \u003csld:LineSymbolizer\u003e \u003csld:Stroke\u003e \u003csld:CssParameter name=\"stroke\"\u003e#8000FF\u003c/sld:CssParameter\u003e \u003csld:CssParameter name=\"stroke-width\"\u003e3.000\u003c/sld:CssParameter\u003e \u003c/sld:Stroke\u003e \u003c/sld:LineSymbolizer\u003e \u003c/sld:Rule\u003e \u003c/sld:FeatureTypeStyle\u003e \u003c/sld:UserStyle\u003e \u003c/sld:NamedLayer\u003e \u003c/sld:StyledLayerDescriptor\u003e';\n\n\nparser\n  .readStyle(sldString)\n  .then(({output: sldObject}) =\u003e console.log(sldObject))\n  .catch(error =\u003e console.log(error));\n```\n\n## \u003ca name=\"funding\"\u003e\u003c/a\u003eFunding \u0026 financial sponsorship\n\nMaintenance and further development of this code can be funded through the\n[GeoStyler Open Collective](https://opencollective.com/geostyler). All contributions and\nexpenses can transparently be reviewed by anyone; you see what we use the donated money for.\nThank you for any financial support you give the GeoStyler project 💞\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeostyler%2Fgeostyler-sld-parser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgeostyler%2Fgeostyler-sld-parser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeostyler%2Fgeostyler-sld-parser/lists"}