emi-recipe-renderer
v0.6.5
Published
Browser renderer for exported EMI recipe layouts
Readme
emi-recipe-renderer
Browser library for exported EMI recipe layouts. Not affiliated with EMI.
Bundles are produced in-game by the minecraft-web-export Forge mod.
Install
npm install emi-recipe-renderer<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/emi.min.css">
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/emi.min.js"></script>Usage
<div class="emi-recipe" data-recipe-id="minecraft:iron_pickaxe"></div>
<script>
EmiRecipeRenderer.mountAll({
baseUrl: '/path/to/emi-bundle',
locale: 'en_us',
});
</script>baseUrl is the EMI export root. Elements need class="emi-recipe" and data-recipe-id.
Validate a bundle (Node)
npx emi-bundle-validate /path/to/emi-bundle-rootimport { validateBundleRoot } from 'emi-recipe-renderer/validate';
validateBundleRoot('/path/to/emi-bundle-root');Development
npm ci && npm run build && npm test