Now that we have assigned an archive to a mapping, we can remove the components/api
folder. But before that, let's experiment with some of the settings we have in the mappings.
If you look in the listing of Mappings, you will see the Primary column. You have a choice of Resource or Archive. Currently, our /api
mapping points both to the components/cfcs
folder and the archive we created. Since the Primary setting is set to Resource, it means that any changes we do to our template will be reflected since that is the primary resource with a backup of the Archive.
We can actually now remove the Resource path and save the mapping and our code will now access the archive solely.
Let's see how this works.