原創(chuàng)|使用教程|編輯:龔雪|2019-07-11 10:01:55.197|閱讀 948 次
概述:Kendo UI目前最新提供Kendo UI for jQuery、Kendo UI for Angular、Kendo UI Support for React和Kendo UI Support for Vue四個控件,本教程為大家介紹如何開始使用Kendo UI,如何在項目中托管Kendo UI、安裝Bower包 、使用CDN服務等。
# 界面/圖表報表/文檔/IDE等千款熱門軟控件火熱銷售中 >>
相關鏈接:
Kendo UI目前最新提供Kendo UI for jQuery、Kendo UI for Angular、Kendo UI Support for React和Kendo UI Support for Vue四個控件。Kendo UI for jQuery是創(chuàng)建現(xiàn)代Web應用程序的最完整UI庫;Kendo UI for Angular是專用于Angular開發(fā)的專業(yè)級Angular UI組件;Kendo UI Support for React支持React Javascript框架,更快地構建更好的應用程序;Kendo UI Support for Vue為Vue技術框架提供可用的Kendo UI組件,更快地構建更好的Vue應用程序。
更多資源請查看【Kendo UI視頻教程集合】【Kendo UI TreeView功能詳解】【Kendo UI經典開發(fā)案例賞析】
根據(jù)項目和參數(shù)要求,你可以:
要在項目中托管Kendo UI,你需要:
下載任何Kendo UI軟件包后,下面列出的文件夾將托管在您的本地存儲庫中。
要在項目中使用Kendo UI,請包含所需的JavaScript和CSS文件。
Step 1:從bundle存檔中提取 /js和/styles目錄,并將它們復制到Web應用程序根目錄。
Step 2:在HTML文檔的head標記中包含Kendo UI JavaScript和CSS文件,驗證在主題CSS文件之前注冊了公共CSS文件。
<!DOCTYPE html><html><head><title>Welcome to Kendo UI!</title><!-- Common Kendo UI CSS for web widgets and widgets for data visualization. --><link href="styles/kendo.common.min.css" rel="stylesheet" /> <!-- (Optional) RTL CSS for Kendo UI widgets for the web. Include only in right-to-left applications. --> <link href="styles/kendo.rtl.min.css" rel="stylesheet" type="text/css" /> <!-- Default Kendo UI theme CSS for web widgets and widgets for data visualization. --> <link href="styles/kendo.default.min.css" rel="stylesheet" /> <!-- (Optional) Kendo UI Hybrid CSS. Include only if you will use the mobile devices features. --> <link href="styles/kendo.default.mobile.min.css" rel="stylesheet" type="text/css" /> <!-- jQuery JavaScript --> <script src="js/jquery.min.js"></script> <!-- Kendo UI combined JavaScript --> <script src="js/kendo.all.min.js"></script> </head> <body> Hello World! </body> </html>
注意:代碼示例以后假設Kendo UI scripts和stylesheets現(xiàn)在已添加到文檔中。
Step 3:初始化一個小部件
以下示例演示如何初始化DatePicker小部件。
<!-- HTML element from which the DatePicker would be initialized --> <input id="datepicker" /> <script> $(function() { // Initialize the Kendo UI DatePicker by calling the kendoDatePicker jQuery plugin $("#datepicker").kendoDatePicker(); }); </script>
以下示例演示了DatePicker小部件的完全初始化。
<!DOCTYPE html> <html> <head> <title>Welcome to Kendo UI!</title> <link href="styles/kendo.common.min.css" rel="stylesheet" /> <link href="styles/kendo.default.min.css" rel="stylesheet" /> <script src="js/jquery.min.js"></script> <script src="js/kendo.all.min.js"></script> </head> <body> <input id="datepicker" /> <script> $(function() { $("#datepicker").kendoDatePicker(); }); </script> </body> </html>
Bower是一個流行的Web管理程序包管理器,用于處理框架、庫、資產和實用程序。
Kendo UII維護2個Bower包:
所有正式版本,Service Pack和內部版本都會上傳到它們中。
截至Kendo UI 2016 Q2(2016.2.504)更新:
Kendo UI CDN托管在上。 要訪問CDN服務,您可以使用不同的方法。
掃描關注慧聚IT微信公眾號,及時獲取最新動態(tài)及最新資訊
本站文章除注明轉載外,均為本站原創(chuàng)或翻譯。歡迎任何形式的轉載,但請務必注明出處、不得修改原文相關鏈接,如果存在內容上的異議請郵件反饋至chenjj@fc6vip.cn
文章轉載自:慧都網(wǎng)