.alfredui Folder Structure

At their most basic, Alfred UIs only require one folder whose name can be anything ending in .alfredui and a JSON file inside it named (exactly) ui.json.

package.alfredui
 └─ ui.json

With that in place, you can follow any structure you desire to organise the rest of your UI and its required files. Paths referenced inside UIs, such as scripts for actions or separate files for components and layouts are relative to the root .alfredui folder.

Example of a mock complex UI:

package.alfredui
 ├─ ui.json
 ├─ components/
 │   ├─ sort-buttons.json
 │   └─ sidebar.json
 ├─ scripts/
 │   └─ filter-produce.js
 └─ resources/
     ├─ apple.png
     ├─ banana.png
     └─ carrot.png