-
Book Overview & Buying
-
Table Of Contents
Getting Started with Taipy
By :
In this section, we’ll see how to create content dynamically for applications. The big difference between this approach and what we saw in the previous part of this chapter is that we’re going to create the content from functions. We won’t create files and links to internal or external URLs. To add our content dynamically, we also use the part element, but we use the content argument instead of page. Let’s see a couple of use cases!
In this section, we’ll see how to add Folium maps to our app. Figure 14.2-3 shows the map in the Parishes tab. It displays all the accommodation locations from Open Street Maps in Andorra. The code is in /src/algorithms/folium_map.py. Let’s explain it!
We start by creating a class called FoliumMap, and we define the __init__ constructor with input attributes (in this case, a GeoPandas GeoDataFrame) and outputs (in this case, a Folium map object that’s...