Jump to content

Module:NavboxGenerator/doc

From Deadlock Wiki
Revision as of 21:03, 25 October 2024 by Sur (talk | contribs) (init)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

This is the documentation page for Module:NavboxGenerator

Not finished.

Overview

Create's a navbox from a json file for input where keys are a title div container, and value "Display" is the display text. Each title div container gets smaller and smaller the further it is in the json.

Example

The input can be seen at Data:ItemNavbox.json

{{#invoke:NavboxGenerator|createNavbox|Data:ItemNavbox.json}}

Outputs

Lua error: bad argument #1 to 'mw.loadJsonData' ('Data:ItemNavbox.json' is not a valid JSON page).


Needed changes

1. Style/Formatting made prettier 2. A way to have the json iterated in order; for some reason mw.loadJsonData doesn't load the keys in order they appear.


This is not used on any pages currently.