Saving and Validating Changes

flamingo IDE allows automatic or manual saving of changes made in project and ensures their validation.

Automatic Saving

All changes you make in your project are saved automatically as soon as you make them. So you don’t need to worry about pressing the “Save” button or any shortcut keys to avoid losing your work in case of some system error or accident. This behavior is enabled by default.

But you should keep in mind that all code you enter is constantly being validated by flamingo IDE. And if code is not valid , it is lost when you close the tab or end flamingo IDE session.

In case flamingo IDE detects an error, the Error icon is displayed on the margin indicator bar that is highlighted in red, and bug icon appears on the tab title. To see the description of an error, point to the Error error icon and read the tooltip.

Validation error

By principles of multi-user development resources edited by one user cannot be edited by other users working on the same project.

In case invalid content was entered in the active resource, flamingo IDE does its best to store these changes as long as possible so that user has chance to return to this resource and correct it later. If user leaves invalid resource by switching to another resource the system stores these changes until another user enters valid code or until the first user closes flamingo IDE. If another user inserts correct code in the invalid resource, invalid code is replaced by valid code automatically (i.e. invalid code is lost).

Before user switches to another resource leaving invalid code behind, the system will show notification saying that there is some invalid content in the resource they are going to leave and it can be replaced by another user:

Invalid content message

Syntax in entities and files that can be edited is highlighted for your convenience.

Manual Saving

If you don’t want flamingo IDE to save changes automatically, you can disable the autosave mode:

  1. Open flamingo IDE settings by clicking the Preferences button on the left sidebar.

  2. Turn the Auto Save option off.

  3. Click Close.

Now if you make any changes, the resource header becomes bold and you should press Ctrl+S (Command+S for OS X users) on your keyboard or click the Save Changes button on the Code Editor toolbar to save them.

To prevent losing changes when working in the manual save mode, flamingo IDE checks if there are any unsaved changes every time when you are switching among tabs or attempting to exit the system. If it detects such changes, the corresponding notification is shown.

In case connection was lost or browser window with flamingo IDE did not shut down correctly and there were unsaved changes, the system will ask you if you want to restore those changes or load current resource version from the server when you open IDE next time. Note that if another user made any updates to this resource while you were offline, all changes are lost and no notification is shown.

Template and Snippet Validation

In templates and snippets, flamingo IDE validates template syntax. That is, all code used for introducing dynamic content and specific flamingo API functions is checked.

If error in template is not critical, you are informed about it as described above (with error icon and highlighting). If it is critical and template cannot work correctly, the corresponding message is shown.

In templates, parameters are validated as well.

CSS validation

Code in CSS files is validated in accordance with CSS standards .

Validation of Public Resources Availability

When you add such resources as images, CSS and JavaScript files, you want to be sure these files really exist in your project. Misprints in file names and paths may result in broken images, unapplied styles and scripts, etc. To avoid such problems, flamingo IDE informs you about files that are not available in your project as soon as you add them to your template, snippet or any other resource. Watch out for yellow warning signs on the margin indicator bar that mark such instances:

Warning for file that does not exist in the project

Note that if the mentioned public resource is added during the workflow, the warning sign will disappear right away as the code is being constantly validated by the IDE.