openBuild
  • Introduction
    • Introduction
    • The Framework
    • The Library
    • Release Notes
  • Core Concepts
    • Bubble vs openBuild
    • Responsive Design
      • Repeating groups
      • Advanced Responsiveness
    • Styles
      • Typography
      • Colors
      • Groups & Box Shadow
      • Inputs
      • Buttons
      • Style Variations
      • Changing styles
      • Custom CSS
    • Pages
      • index
      • base-menu
      • base-top
      • base-ribbon
      • base-mobile
      • admin
      • verify
      • styleguide
      • terms
      • login
      • reset_pw
      • privacy
      • 404
      • Menu
      • Base Layouts
  • WORKING WITH the framework
    • Getting Started
    • Navigation
      • Go to page
      • Navigation through custom states
      • Navigation through URL parameters
      • Navigation through URL parameters with Option sets
    • Data & Workflows
      • Custom States
      • Custom Events
      • Working with Reusables
      • CRUD
      • Source Popup
      • Backend Workflows
    • Users and Roles
    • Signup, Login, Password reset
    • Security & Privacy
      • Authenticating endpoints
    • Transactional Email
      • Setup Sendgrid
      • Setup Postmark
    • Alerts and Confirmations
    • Customization
    • Best Practices
      • Syntax
      • Color Coding
  • openBuild Library
    • Chrome Extension
  • Framework Elements
    • Menus
    • Option sets
    • Plugins
    • API Connector
    • User Access Management
    • CRUD Floating Group
    • CRUD Popup
    • Data Table
    • Security Redirect
    • Mail management
    • User Settings
    • Header & Footer
Powered by GitBook
On this page
  • Database
  • Inputs
  • Elements
  • States:
  • Custom events:
  • API Workflows
  • Workflows
  1. WORKING WITH the framework
  2. Best Practices

Syntax

PreviousBest PracticesNextColor Coding

Last updated 2 years ago

Database

We recommend the naming convention when it comes to naming database fields.

Camel case is the practice of writing phrases without spaces or punctuation, indicating the separation of words with a single capitalized letter, and the first word starting with either case e.g. firstName, lastName, fullDescription.

When linking to other data types follow the upper camel case method which uses an initial uppercase letter e.g. when the User have a field linking to a company data type: Company.

Following this convention you will know that fields starting with uppercase are linked to other data types and those starting out with lowercase letters are fields saved directly on the data type (such as text, numbers, and dates).

Linking field to option sets should start with lowercase.

Inputs

All inputs elements should follow this syntax:

Thanks to this convention searching for the right input will be fast and easy, as you will have multiple points of reference to the input and they are distinguished enough visually to locate them in the conditional dropdowns and field searches.

Elements

When building in the app logic most of the time we heavily really on referring to elements that store values.

Ideally, the naming convention makes things easier for the developer to build fast and the most important factor enabling that is searching for the elements from the workflows tab:

Conditional dropdown:

  • When using a group as a data source its best to keep the same naming conventions for all of the source groups and as well using visual cues that will help us find and locate it faster:

  • Source: e.g. 🚩 Source - Property

Actionable elements such as buttons, icons, texts, link and other group elements follow this convention: [elementType].[actionType]

e.g btn.createUser, icon.toggleMenu, group.closePopup

Tip: Best to rename things as you go, doing it all at the end of the build is not efficient in our experience.

States:

States should follow the same naming convention as database fields. We recommend using Icon indication to see its representation in actions ⚡️ e.g. ⚡️Product. The icon will act as another visual cue that will help you distinguish between custom states and other input types.

Custom events:

For better organization and reading experience, we recommend naming all custom events workflows with capitalized letters and icons, which play a supporting role in distinguishing between different types of custom events.

API Workflows

Endpoints naming convention should use a dash when using multiple keywords:

  • e.g. send-email vs sendemail

General tips:

  • Avoid using jargon e.g. email-update vs ems

  • No abridging e.g. phone-update vs tel-no

Workflows

Try to be descriptive when renaming your actions or workflows.

  • Make a change to the Current User -> Update Current User Personal Data

  • Scheduled API workflow -> API: Send Invite Email

  • Make changes to thing... -> Add new Project to Company

object.input-type.field e.g. should be used to modify the User’s email.

Read how to centralize the data management on a page in .

There are exceptions to this rule which is making the API endpoint public. You might consider making the endpoint more cryptic especially if you are not using authentication. (See can read about webhook authentication )

user.input.email
this section
in this section
Camel case
User datatype
Texts and inputs referring the 🚩 Source - User
Setting state
Referring to states in searches
ustom events among other workflows