Skip to content

Platform-OS/tutorials-contact-us

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

67 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

platformOS Example Contact Us Form

This repository contains the final code for the Contact Us form tutorial on platformOS. This tutorial is designed to help you build a comprehensive Contact Us form, leveraging various platformOS features such as Commands, Validators, Events, data display, and logging.

The full tutorial is available on the platformOS documentation site.

Setup

To deploy the code to your own instance, follow these steps:

  1. Sign up on the Partner Portal
  2. Create an instance
  3. Install pos-cli

Ensure you have pos-cli installed globally. If not, you can install it using npm:

npm install -g @platformos/pos-cli
  1. Authenticate your environment
pos-cli env add --url https://YOUR-INSTANCE.staging.oregon.platform-os.com staging
  1. Deploy the code

Deploy the code to your instance:

pos-cli deploy staging

Or sync your changes:

pos-cli sync staging

Using the Tutorial

This repository is used in the Contact Us tutorial on the official platformOS documentation site.

Because the tutorial is written step by step, we provide checkpoints as Git tags. Each checkpoint matches the exact state of the codebase at the end of a chapter. This way you can check out only the part of the code that is relevant to the chapter you are following, without being confused by later changes.

Available checkpoints

  • checkpoint-defining-email — matches the result of Defining the email chapter
  • checkpoint-testing — matches the result of Testing the contact create command chapter
  • checkpoint-common-styling — matches the result of Styling the Form chapter

How to use a checkpoint

  1. Clone this repository (if you haven’t already):

    git clone https://github.com/Platform-OS/tutorials-contact-us.git
    cd tutorials-contact-us
  2. Make sure you have all tags:

    git fetch --tags
  3. Check out the tag that matches the chapter you are following, for example:

    git checkout tags/checkpoint-testing

This puts your repository into the exact state of the code as it is shown in the documentation chapter. You’ll be in a detached HEAD state, which is normal for tags. If you want to experiment and make edits, create a branch from that state:

git switch -c my-experiments

To return to the latest version of the code on main:

git checkout main
git pull

Contributing

If you find any issues or have suggestions for improvements, feel free to open an issue or submit a pull request.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors