Module Structure
All modules in FreshJuice are located in:Module Categories
Modules are organized into the following categories:Content Modules
UI components like accordions, cards, buttons, tabs, and lists
Navigation Modules
Navigation bars, menus, footers, and navigation components
Blog Modules
Blog listing, pagination, related posts, and author information
Testimonial Modules
Various testimonial layouts and styles
Module Breakdown
FreshJuice includes 37 modules across different categories:- Content Modules: 16 modules (accordion, button, card, tabs, lists, media, etc.)
- Navigation Modules: 6 modules (navigation bars, menus, footers)
- Blog Modules: 5 modules (blog listing, pagination, related posts)
- Testimonial Modules: 4 modules (various testimonial layouts)
- Pricing Modules: 3 modules (pricing cards and tables)
- Stats Modules: 3 modules (statistics and timeline displays)
How Modules Work
Modules in HubSpot are reusable components that can be added to templates and drag-and-drop areas.Module Structure
Each module directory contains:Module Metadata (meta.json)
Themeta.json file defines module properties:
Module Types
Standard Modules
Most modules are standard modules that can be added to drag-and-drop areas:Global Modules
Some modules are marked asglobal: true in their meta.json. These include:
- Global Footer - Site-wide footer
- Global Footer for Landing Pages - Simplified footer for landing pages
- Post Author - Blog post author information
- Scroll to Top - Scroll to top button
- Share Buttons - Social sharing buttons for blog posts
Using Modules
In Templates
Modules can be added directly to templates:In Drag-and-Drop Areas
Modules are available in the HubSpot page editor for drag-and-drop areas:Module Availability
Modules can be restricted to specific content types:- LANDING_PAGE - Available for landing pages
- SITE_PAGE - Available for site pages
- BLOG_POST - Available for blog posts
- BLOG_LISTING - Available for blog listing pages
Module Development
For information on creating custom modules, see the Creating Modules guide.
Module Fields
Modules usefields.json to define editable fields:
Module Styling
Modules can include Tailwind CSS classes and custom CSS:Best Practices
Use semantic module names
Use semantic module names
Choose descriptive names that clearly indicate the module’s purpose (e.g.,
navigation-bar instead of nav).Keep modules focused
Keep modules focused
Each module should have a single, clear purpose. Avoid creating overly complex modules that try to do too much.
Make modules configurable
Make modules configurable
Use fields to make modules flexible and reusable across different contexts.
Follow naming conventions
Follow naming conventions
Use kebab-case for module directory names (e.g.,
blog-listing.module).Test across content types
Test across content types
Ensure modules work correctly in all supported content types (pages, blog posts, etc.).
Module Performance
FreshJuice modules are optimized for performance:- Lazy loading for videos (Lite YouTube, Lite Vimeo)
- Minimal JavaScript - modules use Alpine.js for lightweight interactivity
- CSS optimization - Tailwind CSS with PurgeCSS removes unused styles
- Modern techniques - uses performance-focused libraries and patterns
Next Steps
Explore specific module categories:Content Modules
Accordion, Button, Card, Tabs, Lists, and more
Navigation Modules
Navigation bars, menus, and footers
Blog Modules
Blog listing, pagination, and related posts
Testimonial Modules
Various testimonial layouts and styles