What We’re Building
In this tutorial, we’ll create a Weather Dashboard that:- Shows current weather for a city
- Displays a 5-day forecast
- Lets users search for different locations
Prerequisites
- A Constants account (sign up here)
- About 10 minutes of your time
Step 1: Start with a Clear Prompt
From your dashboard, click Create new App. In the prompt input, enter:Step 2: Watch Generation
Click Generate and watch as Constants builds your app. You’ll see:- Analyzing - Constants understands your requirements
- Generating - The app code is being written
- Complete - Your app is ready!
Step 3: Explore Your App
Once generated, you’ll see your Weather Dashboard. Try it out:- Enter a city name in the search box
- Click search or press Enter
- View the current conditions and forecast
The weather data is simulated by default. For real weather data, you can describe that in your prompt and Constants will handle the integration.
Step 4: Modify Your App
Let’s make some improvements. Click Modify and enter:Step 5: Save and Access Later
Your Worker is automatically saved to My Apps. You can:- Run it anytime from your dashboard
- Modify it with new instructions
- Export it to GitHub for further development
- Share it with others via a unique link
Understanding the Interface
Run Button
Run Button
Modify Button
Modify Button
View Code
View Code
See the generated Python code. This is helpful for learning or if you want to export and modify it yourself.
Export to GitHub
Export to GitHub
Push your Worker to a GitHub repository. You’ll need to connect your GitHub account first.
Best Practices
Start Simple
Begin with core functionality, then add features through modifications. This leads to better results than complex initial prompts.
Be Descriptive
Use specific terms and describe the user experience you want. “Clean design” is good, but “minimal white background with subtle shadows” is better.
Iterate Often
Don’t try to get everything perfect in one prompt. Use the modify feature to refine your app step by step.
Check the Code
Looking at generated code helps you understand what’s possible and can inform better prompts.
