主权项 |
1. A non-transitory computer-readable medium embodying a program executable in a first computing device, wherein the program, when executed, causes the first computing device to at least:
obtain a request for a resource from a second computing device, the request including a version identifier; resolve a location of resource data for generating the resource, wherein data associated with the request determines a cascaded resource group comprising a cascade configuration and a variants configuration, the cascade configuration specifying a sequenced listing of cascaded resource groups and the variants configuration defining a hierarchy of variants for replacement in the resource, and wherein the location is a first one of the sequenced listing of cascaded resource groups; resolve a variant in the resource data into a text string by determining a first one of the sequenced listing of cascaded resource groups in which a definition of the variant is present; transform a link to another resource within the resource data by encoding a version identifier of the another resource within the link; generate the resource from the resource data for presentation to the second computing device, wherein the resource data is loaded from a data cache when the version identifier is less than or equal to a version identifier associated with the resource data in the data cache, and the resource data is loaded from a data store when the version identifier is greater than the version identifier associated with the resource data in the data cache; and substitute a variant from the hierarchy of variants into the resource in place of an identifier in the resource during generation of the resource. |