Basics of building modules
Create a new file
To create a module, click the New button in the Finder panel on the left of the screen, choose New File.
Choose your file type
In the resulting dialog box, choose Module.
Choose your module type
In the next dialog, enter a name for your module and choose where you’d like to use it. It’s important to note that there are technical differences between these module types that make them incompatible. Refer to the editor section below for details. For this example, we’ll create a module for page and blog templates. Leave Local module selected and click Create.
Add a field
With your new module selected in the Finder panel, click on Add field in the Inspector section on the right side of the screen.
There are many new field options which are covered in detail in the reference section of this doc. For this example, choose the Text Field in the Content column on the left of the Add field menu.
Add default content
Give your new field a name and add some Default text.
Add your field to the module markup
Click Copy snippet in the HubL variable name section of the field editor. Paste the snippet into the HTML + HUBL section of the Editor in the center or the screen.
This Editor is discussed in detail here.
Exit field editing
To exit editing for this new field and return to editing the entire module, click the module icon in the breadcrumbs at the top of the Inspector.