I was playing around with themepark for the first time today, specifically with
regards to admin boundaries (as you probably saw in my PR) and I was wondering
how I might be able to pick out internationalized names (e.g. `name:en`,
`name:de`, `name:fr`) without having to modify the lua code. Is it possible to
pass a kind of global param that is accessible by osm2pgsql/themepark? Because
then you could have a helper function like (in Python because I don't know Lua
off the top of my head):
```
LANGUAGE = "en" # Passed as global param upon script invokation
def tag_i18n(tag_name, language):
if "{tags[language]}:{tag_name}" is None:
return {tag_name}
return "{tags[language]}:{tag_name}"
print(f"This place is called {tag_i18n('name')}.")
```
--
Reply to this email directly or view it on GitHub:
https://github.com/osm2pgsql-dev/osm2pgsql/discussions/2317
You are receiving this because you are subscribed to this thread.
Message ID: <osm2pgsql-dev/osm2pgsql/repo-discussions/[email protected]>_______________________________________________
Tile-serving mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/tile-serving