.. _templates:
Templates in GeoMoose
=====================
GeoMoose uses Mark.up templates to handle the duties of converting
results to something more readable by users. More information on Mark.up
and its template syntax can be found
`here. `__
General concepts
----------------
Internally, GeoMoose uses `GeoJSON `__ to represent
features. For rendering results from services (Identify, Select, Search)
GeoMoose will take those features and use Mark.up to render them to
HTML. As seen here:
.. raw:: html
.. code:: xml
{{ properties.OWNER_NAME }}
]]>
.. raw:: html
The template above is named "search" and will be used by the search tool
in order to render any features it recieves from the server.
Aliasing templates
------------------
It is sometimes preferred to have features render the same way no matter
which service is used to find them. GeoMoose supports this by using
template aliases. For example:
.. raw:: html
.. code:: xml
{{ properties.OWNER_NAME }}
]]>
.. raw:: html
Remote templates
----------------
When a Mapbook starts to grow, having all the templates inside of it can
make maintenance increasingly difficult. GeoMoose supports having
templates that can be downloaded only when they are needed:
.. raw:: html
.. code:: xml
.. raw:: html
Then a ``./templates/parcel-search.html`` file would be needed which
contains the same style Mark.up template that would have otherwise been
directly in the mapbook:
.. raw:: html
.. code:: html
{{ properties.OWNER_NAME }}
.. raw:: html