목차
jQuery Templates and Data Linking (and Microsoft contributing to jQuery)
Contributing to jQuery" >Contributing to jQuery
jQuery Template Support" >jQuery Template Support
Support for Client Data-Linking" >Support for Client Data-Linking
Combining Templating and Data Linking" >Combining Templating and Data Linking
위 시나리오의 작동 코드 예제 다운로드" >위 시나리오의 작동 코드 예제 다운로드
요약" >요약
웹 프론트엔드 JS 튜토리얼 jQuery 템플릿 기술 및 데이터 바인딩 구현 code_jquery

jQuery 템플릿 기술 및 데이터 바인딩 구현 code_jquery

May 16, 2016 pm 06:26 PM
jquery 데이터 바인딩 주형

好消息来了,微软开发出了这样的框架,这是对jQuery的一个扩展,从此以后要在浏览器上动态显示服务器端Web Service返回的数据将变得如同用服务器端控件显示数据一样容易。

这个技术就叫jQuery templates and data linking ,这是微软对jQuery做的一个扩展。这种扩展需要jQuery官方的审核,然后才能被包含在jQuery中。据ScottGu的博客上说,此扩展正在等待审核阶段。但是这些功能却是非常强大而且实用,我就先把它转过来了,先睹为快。

在编写AJAX应用时,经常需要利用JavaScript在页面上显示数据,jQuery模板(jQuery Templates)和数据绑定(Data Linking)提供了一种方便的途径将JavaScript数据显示在HTML页面上,数据可以呈现为各种元素,如普通文本、TextBox、列表等。Data Linking这个单词直译应该作数据链接,但是我觉得数据绑定这个词更加能够反映这种技术的能容,而且符合ASP.NET习惯用法。在Scott Guthrie的博客中也这样说,原来他们也想称这种技术为data binding而不是data linking,但是由于jQuery中已经有binding这个术语了,指的是另外的东西,为了不至于引起混淆,所以就只好另外给它起个名字,叫data linking了。

我下面把这个博客转过来,有时间则翻译一下。

以下全文引用自ScottGu的博客

 

jQuery Templates and Data Linking (and Microsoft contributing to jQuery)

The jQuery library has a passionate community of developers, and it is now the most widely used JavaScript library on the web today.

Two years ago I announced that Microsoft would begin offering product support for jQuery, and that we'd be including it in new versions of Visual Studio going forward. By default, when you create new ASP.NET Web Forms and ASP.NET MVC projects with VS 2010 you'll find jQuery automatically added to your project.

A few weeks ago during my second keynote at the MIX 2010 conference I announced that Microsoft would also begin contributing to the jQuery project.  During the talk, John Resig -- the creator of the jQuery library and leader of the jQuery developer team – talked a little about our participation and discussed an early prototype of a new client templating API for jQuery.

In this blog post, I'm going to talk a little about how my team is starting to contribute to the jQuery project, and discuss some of the specific features that we are working on such as client-side templating and data linking (data-binding).

Contributing to jQuery

jQuery has a fantastic developer community, and a very open way to propose suggestions and make contributions.  Microsoft is following the same process to contribute to jQuery as any other member of the community.

As an example, when working with the jQuery community to improve support for templating to jQuery my team followed the following steps:

  1. We created a proposal for templating and posted the proposal to the jQuery developer forum (http://forum.jquery.com/topic/jquery-templates-proposal and http://forum.jquery.com/topic/templating-syntax ).
  2. After receiving feedback on the forums, the jQuery team created a prototype for templating and posted the prototype at the Github code repository (http://github.com/jquery/jquery-tmpl ).
  3. We iterated on the prototype, creating a new fork on Github of the templating prototype, to suggest design improvements. Several other members of the community also provided design feedback by forking the templating code.

There has been an amazing amount of participation by the jQuery community in response to the original templating proposal (over 100 posts in the jQuery forum), and the design of the templating proposal has evolved significantly based on community feedback.

The jQuery team is the ultimate determiner on what happens with the templating proposal – they might include it in jQuery core, or make it an official plugin, or reject it entirely.  My team is excited to be able to participate in the open source process, and make suggestions and contributions the same way as any other member of the community.

jQuery Template Support

Client-side templates enable jQuery developers to easily generate and render HTML UI on the client.  Templates support a simple syntax that enables either developers or designers to declaratively specify the HTML they want to generate.  Developers can then programmatically invoke the templates on the client, and pass JavaScript objects to them to make the content rendered completely data driven.  These JavaScript objects can optionally be based on data retrieved from a server.

Because the jQuery templating proposal is still evolving in response to community feedback, the final version might look very different than the version below. This blog post gives you a sense of how you can try out and use templating as it exists today (you can download the prototype by the jQuery core team at http://github.com/jquery/jquery-tmpl or the latest submission from my team at http://github.com/nje/jquery-tmpl). 

jQuery Client Templates

You create client-side jQuery templates by embedding content within a

핫 AI 도구

Undresser.AI Undress

Undresser.AI Undress

사실적인 누드 사진을 만들기 위한 AI 기반 앱

AI Clothes Remover

AI Clothes Remover

사진에서 옷을 제거하는 온라인 AI 도구입니다.

Undress AI Tool

Undress AI Tool

무료로 이미지를 벗다

Clothoff.io

Clothoff.io

AI 옷 제거제

Video Face Swap

Video Face Swap

완전히 무료인 AI 얼굴 교환 도구를 사용하여 모든 비디오의 얼굴을 쉽게 바꾸세요!

뜨거운 도구

메모장++7.3.1

메모장++7.3.1

사용하기 쉬운 무료 코드 편집기

SublimeText3 중국어 버전

SublimeText3 중국어 버전

중국어 버전, 사용하기 매우 쉽습니다.

스튜디오 13.0.1 보내기

스튜디오 13.0.1 보내기

강력한 PHP 통합 개발 환경

드림위버 CS6

드림위버 CS6

시각적 웹 개발 도구

SublimeText3 Mac 버전

SublimeText3 Mac 버전

신 수준의 코드 편집 소프트웨어(SublimeText3)

jQuery에서 PUT 요청 방법을 사용하는 방법은 무엇입니까? jQuery에서 PUT 요청 방법을 사용하는 방법은 무엇입니까? Feb 28, 2024 pm 03:12 PM

jQuery에서 PUT 요청 방법을 사용하는 방법은 무엇입니까? jQuery에서 PUT 요청을 보내는 방법은 다른 유형의 요청을 보내는 것과 유사하지만 몇 가지 세부 사항과 매개 변수 설정에 주의해야 합니다. PUT 요청은 일반적으로 데이터베이스의 데이터 업데이트 또는 서버의 파일 업데이트와 같은 리소스를 업데이트하는 데 사용됩니다. 다음은 jQuery에서 PUT 요청 메소드를 사용하는 구체적인 코드 예제입니다. 먼저 jQuery 라이브러리 파일을 포함했는지 확인한 다음 $.ajax({u를 통해 PUT 요청을 보낼 수 있습니다.

PPT 마스크를 추가하는 방법 PPT 마스크를 추가하는 방법 Mar 20, 2024 pm 12:28 PM

PPT 마스킹에 관해서는 아직 생소하신 분들이 많을 텐데요. 대부분의 사람들은 PPT를 만들 때 잘 이해하지 못하고 그냥 마음에 드는 대로 만들어서 만드는 경우가 많기 때문에 PPT 마스킹이 무엇인지도 모르고 이해하지도 못하는 분들이 많습니다. 이 마스크가 어떤 역할을 하는지는 알지만, 사진을 덜 단조롭게 만들 수 있을지도 모르겠습니다. 배우고 싶은 친구들, PPT 마스크를 좀 덜 단조롭게 만들어 보세요. 그렇다면 PPT 마스크를 추가하는 방법은 무엇입니까? 아래를 읽어주세요. 1. 먼저 PPT를 열고 빈 그림을 선택한 다음 [배경 형식 설정]을 마우스 오른쪽 버튼으로 클릭하고 단색을 선택합니다. 2. [삽입] 클릭, 워드아트 단어 입력 3. [삽입] 클릭, [도형] 클릭

jQuery 팁: 페이지에 있는 모든 태그의 텍스트를 빠르게 수정하세요. jQuery 팁: 페이지에 있는 모든 태그의 텍스트를 빠르게 수정하세요. Feb 28, 2024 pm 09:06 PM

제목: jQuery 팁: 페이지에 있는 모든 태그의 텍스트를 빠르게 수정하세요. 웹 개발에서는 페이지의 요소를 수정하고 조작해야 하는 경우가 많습니다. jQuery를 사용할 때 페이지에 있는 모든 태그의 텍스트 내용을 한 번에 수정해야 하는 경우가 있는데, 이는 시간과 에너지를 절약할 수 있습니다. 다음은 jQuery를 사용하여 페이지의 모든 태그 텍스트를 빠르게 수정하는 방법을 소개하고 구체적인 코드 예제를 제공합니다. 먼저 jQuery 라이브러리 파일을 도입하고 다음 코드가 페이지에 도입되었는지 확인해야 합니다. &lt

함수 오버로딩 및 재작성에 대한 C++ 템플릿 전문화의 효과 함수 오버로딩 및 재작성에 대한 C++ 템플릿 전문화의 효과 Apr 20, 2024 am 09:09 AM

C++ 템플릿 전문화는 함수 오버로딩 및 재작성에 영향을 줍니다. 함수 오버로딩: 특수화된 버전은 특정 유형의 다양한 구현을 제공할 수 있으므로 컴파일러가 호출하도록 선택하는 함수에 영향을 줍니다. 함수 재정의: 파생 클래스의 특수 버전은 기본 클래스의 템플릿 함수를 재정의하여 함수를 호출할 때 파생 클래스 개체의 동작에 영향을 줍니다.

jQuery를 사용하여 모든 태그의 텍스트 내용 수정 jQuery를 사용하여 모든 태그의 텍스트 내용 수정 Feb 28, 2024 pm 05:42 PM

제목: jQuery를 사용하여 모든 태그의 텍스트 내용을 수정합니다. jQuery는 DOM 작업을 처리하는 데 널리 사용되는 인기 있는 JavaScript 라이브러리입니다. 웹 개발을 하다 보면 페이지에 있는 링크 태그(태그)의 텍스트 내용을 수정해야 하는 경우가 종종 있습니다. 이 기사에서는 jQuery를 사용하여 이 목표를 달성하는 방법을 설명하고 구체적인 코드 예제를 제공합니다. 먼저 페이지에 jQuery 라이브러리를 도입해야 합니다. HTML 파일에 다음 코드를 추가합니다.

jQuery에서 eq의 역할 및 적용 시나리오 이해 jQuery에서 eq의 역할 및 적용 시나리오 이해 Feb 28, 2024 pm 01:15 PM

jQuery는 웹 페이지에서 DOM 조작 및 이벤트 처리를 처리하는 데 널리 사용되는 인기 있는 JavaScript 라이브러리입니다. jQuery에서 eq() 메서드는 지정된 인덱스 위치에서 요소를 선택하는 데 사용됩니다. 구체적인 사용 및 적용 시나리오는 다음과 같습니다. jQuery에서 eq() 메서드는 지정된 인덱스 위치에 있는 요소를 선택합니다. 인덱스 위치는 0부터 계산되기 시작합니다. 즉, 첫 번째 요소의 인덱스는 0이고 두 번째 요소의 인덱스는 1입니다. eq() 메소드의 구문은 다음과 같습니다: $("s

jQuery 요소에 특정 속성이 있는지 어떻게 알 수 있나요? jQuery 요소에 특정 속성이 있는지 어떻게 알 수 있나요? Feb 29, 2024 am 09:03 AM

jQuery 요소에 특정 속성이 있는지 어떻게 알 수 있나요? jQuery를 사용하여 DOM 요소를 조작할 때 요소에 특정 속성이 있는지 확인해야 하는 상황이 자주 발생합니다. 이 경우 jQuery에서 제공하는 메소드를 사용하여 이 기능을 쉽게 구현할 수 있습니다. 다음은 jQuery 요소에 특정 속성이 있는지 확인하기 위해 일반적으로 사용되는 두 가지 방법을 특정 코드 예제와 함께 소개합니다. 방법 1: attr() 메서드와 typeof 연산자를 // 사용하여 요소에 특정 속성이 있는지 확인

C++ 템플릿과 제네릭을 비교하시나요? C++ 템플릿과 제네릭을 비교하시나요? Jun 04, 2024 pm 04:24 PM

C++에서 템플릿과 제네릭의 차이점: 템플릿: 컴파일 타임에 정의되고, 형식이 명확하며, 효율성이 높고, 코드 크기가 작습니다. 제네릭: 런타임 타이핑, 추상 인터페이스는 유연성과 낮은 효율성을 제공합니다.

See all articles