The Editor

## Overview

**The editor** is where you'll be actually be building your generator. It includes 4 panels. The layout of the panels in the editor is as follows:

## Parts

* **Lists:** You'll spend the majority of your time in this panel writing lists like the examples that you've seen so far. Note that you can also add "comments" in the code panel by writing two forward slashes like this: "// this is a comment" and any text after those two slashes on that line will be ignored by the engine. Comments are just a way for you to leave notes for yourself or others within the code of your generator and they won't affect your generator's output. Pro tip: You can highlight multiple lines and indent or un-indent them all at once with `Tab` and `Shift+Tab`.

* **Tester:** This is a helpful little panel that allows you to test out your lists, and general Perchance expressions. If you've just made a list of animals called "animal" then you can type `the silly [animal]` into the tester and it'll evaluate it to "the silly worm" or "the silly mouse", etc.

* **HTML:** You'll probably want to share your generator with others, so it needs to have a webpage. Webpages are written in a language called "HTML", but don't worry! You don't need to learn HTML or even worry about the HTML panel at all because there are pre-built templates which you can use. If you'd like to learn HTML so you can customize your generator's appearance a bit more, then Khan Academy and Code Academy both have great online courses that are free and will get you up and running with HTML in no time at all.HTML documentation is available at W3Schools .You can also use the layout maker plugin to help you design your generator more intuitively.

* **Preview:** Here's where you get to actually see and test your generator for real. It live-updates as you type so you can test it as you go. You can also disable auto-update and reload your preview manually (there's a checkbox next to the reload button in this panel). There's also a "fullscreen" button in the bottom-left of this panel which will take you to your translator's *actual* webpage so you can copy the link and share it with your pals.

## Notes

If you haven't already, have a play around in the editor for a bit and see what you can make. You can edit and play around with generators but if you'd like to save them, you'll be prompted to signup/login. You'll need a valid email, but you can always use a service like temp mail if you just want to play around. In any case, Perchance only emails you for verification and password resets (you'll need a real email address to recover your account if you forget the password).

You can save your generator by pressing `Ctrl+s` (`Cmd+s` on Mac) or by clicking the "save" button at the top of the screen. When you're logged in you'll see a few extra buttons at the top of the editor: a "settings" button which allows you to change the url of your generator (after you've saved it), and an "account" button which allows you to see a list of all your generators and change your password/email.

Also note the "community" button at the top of the editor - this leads to reddit.com/r/perchance which acts as the community forum for Perchance. Feel free to ask questions and share your generator over there (you'll need to login/signup to reddit).

Checkout the Keyboard Shortcuts to speed up your editing with common shortcuts.