@solisware/electron-menu-i18next API - v1.0.2
    Preparing search index...

    Function localizeMenuTemplate

    • Recursively walks a Menu template and fills in label for any item that has a role but no explicit label, using i18next translations with an English fallback. Items that already set label are left untouched, so you can mix manually-labeled and role-based items freely.

      Does not mutate the input template — returns a new array/tree.

      Type Parameters

      Parameters

      • template: T[]

        The Electron-compatible menu template to localize.

      • options: LocalizeMenuOptions

        The translator, key prefix, and fallback configuration.

      Returns T[]

      A localized copy of the complete menu tree.