Fork me on GitHub

Web application (public)

Public data have the following file structure:

|-- public/
|  |-- css/             # Cascading styles
|  |-- fonts/           # Fonts
|  |-- img/             # Images
|  |-- js/              # Java Scripts 
|  |-- schemes/         # Schemes
|  |-- .htaccess
|  |-- favicon.ico
|  `-- index.php        # Entrance to the application

The entry point to the application is - index.php file.

The main set of Java Sript libraries, services and frameworks have the following file structure:

|-- public/
   |-- js/                  # Java Scripts 
        |-- app/            
        |   |-- bb-todo/    # Components implement the test example `ToDo` 
                            # based on framework `Backbone`
        |   |-- services/   # Services: `Datepicker`, `FormValidation`, `MaskInput`, `Highlight`
        |   |-- app.js      # `App` class
        |   |-- lang.js     # `Lang` class
        |   `-- system.js   # `System` class
        |
        |-- lib/            # Libraries
        `-- main.js         # Initialization Requirejs

The application on the client loads the basic resources via layout app/Views/Layout/base.html.twig.

This includes the following resources:

  • Bootstrap is the most popular HTML, CSS, JS framework for creating flexible, mobile internet projects.
  • Font Awesome gives you scalable vector icons that can instantly be customized - size, color, drop shadow, and anything that can be done with the power of CSS.
  • Google fonts that you can use to display the text on your site.
  • jQuery - JavaScript library that focuses on the interaction between JavaScript and HTML. jQuery library makes it easy to access any DOM element, refer to the attributes and content elements DOM, to manipulate them. Also, jQuery library provides a convenient API for working with AJAX.

Loader (main.js)

Download the client side of the application starts with download of file main.js

Localization

Class Lang is used to provide localization on the client side.

Services

Services for the client application, extend the possibility of creating a user interface.

Backbone

If you create complex one-page application, you can use known JavaScript framework Backbone.