import { world } from "@minecraft/server";
import { itemComponents } from './item_components/index.js';


world.beforeEvents.worldInitialize.subscribe((e) => {
    // Register all of the custom item components
    Object.entries(itemComponents).forEach(([componentIdentifier, customComponent]) => {
        const finalComponentIdentifier = `plank_waao:${componentIdentifier}`;
        e.itemComponentRegistry.registerCustomComponent(finalComponentIdentifier, new customComponent());
    });


});