Jquery template. js front-end template engine, jquerytemplate. js

Source: Internet
Author: User

Jquery template. js front-end template engine, jquerytemplate. js

As a modern application, ajax is widely used, which makes it necessary for front-end engineers to assemble templates and render templates in daily development.

When there was a web, the front-end interaction with the back-end was very straightforward. The browser sent a URL and the back-end returned a assembled HTML string. The browser renders the image. Html may be mixed with some php (or some html in php ). Assemble data and templates on the server side to generate html strings to return to the browser side.

This is no different from a normal webpage. But now, we often use the template technology to solve the problem of front-end coupling.

The front-end uses the template engine to write some tags in html, which has nothing to do with data and logic. The backend parses these tags during rendering to generate HTML strings, such as smarty. In fact, the interaction between the frontend and the backend has already existed on the server.

The following is my own case. It is very intuitive to render the front-end page. You can copy it to see it.

Refer to GitHub for more information.Https://github.com/BorisMoore/jquery-tmpl

1 <! DOCTYPE html> 2 

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.