Interface RecipeWebRenderer


@Experimental public interface RecipeWebRenderer
Renders recipes that were previously exported through RecipeExporter for use in the web-version of the guide.

**NOTE:** This is loaded through the Java ServiceLoader mechanism.

  • Method Details

    • getSupportedTypes

      Set<String> getSupportedTypes()
      Returns the recipe types supported by this renderer. This is the string-form of the RecipeType registration ids, i.e. minecraft:crafting..
      Returns:
      the recipe types supported by this renderer. This is the string-form of the RecipeType registration ids, i.e. minecraft:crafting
    • render

      void render(RecipeWebRenderingContext builder, ExportedRecipe recipe)
      Given a recipe that was previously exported to JSON using RecipeExporter.convertToJson(ResourceKey, Recipe, ResourceExporter), produce HTML suitable for displaying it in the website.

      Note that this method may be given recipes that were exported in previous versions of your mod if you try to update the website for older guide versions. Your code should be lenient and compatible with all previous recipe formats you have exported.