请输入您要查询的百科知识:

 

词条 Midori JavaScript Framework
释义

  1. Features

  2. Use

  3. References

  4. External links

{{Multiple issues|{{Notability|Products|date=March 2016}}{{Primary sources|date=November 2009}}
}}{{lowercase}}{{Infobox software
| name = midori
| developer = Aycan Gulez
| latest release version = 2010.05
| latest release date = {{release date|2010|05|10}}
| status = Abandoned
| genre = Web application framework
| programming language = JavaScript
| license = MIT License
| website = http://www.midorijs.com
}}{{Portal|Free and open-source software}}

midori is an ultra-lightweight[1] JavaScript library that aims to make JavaScript web development easier. It was created by Aycan Gulez and hasn't been updated since June 2010.

Features

  • DOM element selection using CSS selectors
  • Tabs
  • Drag and Drop
  • Effects
  • Pop-up menus
  • Ajax with history support
  • Autocomplete
  • Inline Edit
  • Table row selection
  • DOM, cookie, form, string and array utility methods

Use

midori consists of 10 modules and is available as a single JavaScript file. It can be included within any web page by using the following markup:

midori allows the use of standard CSS syntax to access DOM elements, and supports most CSS2 and CSS3 selectors.[2] There are three ways to work on returned DOM elements.

  • Passing JavaScript code to modify a single property, using the built-in apply() method:

// Sets the background color of all the cells in even rows to "yellow" in the "cities" table

midori.get('#cities tr:nth-child(even) td').apply('style.backgroundColor = "yellow"');

  • Passing a function that takes a single parameter for more complex operations, again using the apply() method:

// Marks the cells whose values are 12 or bigger in the "cities" table

midori.get('#cities td').apply(function (o) {

} );

  • Directly accessing array entries returned by midori.get() is also possible.

// Returns the first div element

var firstDiv = midori.get('div')[0];

References

1. ^10 Promising JavaScript Frameworks
2. ^List of CSS selectors midori supports

External links

  • Official website
  • Documentation
  • Tutorials
{{ECMAScript}}

2 : JavaScript libraries|Software using the MIT license

随便看

 

开放百科全书收录14589846条英语、德语、日语等多语种百科知识,基本涵盖了大多数领域的百科知识,是一部内容自由、开放的电子版国际百科全书。

 

Copyright © 2023 OENC.NET All Rights Reserved
京ICP备2021023879号 更新时间:2024/11/13 1:46:49