Voir aussi;
De la doc:
News, listes d'outils et librairies :
http://jsperf.com/jsPerf - JavaScript performance playground: jsPerf aims to provide an easy way to create and share test cases, comparing the performance of different JavaScript snippets by running benchmarks.
ContentTools is a beautiful & small content editor
Not a wysiwyg editor.
http://markitup.jaysalvat.com/
markItUp! universal markup jQuery editor, is a JavaScript plugin built on the jQuery library. It allows you to turn any textarea into a markup editor. Html, Textile, Wiki Syntax, Markdown, BBcode or even your own Markup system can be easily implemented.
http://code.google.com/p/flexigrid/
Lightweight but rich data grid with re-sizable columns and a scrolling data to match the headers, plus an ability to connect to an XML or JSON data source using Ajax to load the content.
Similar in concept with the Ext Grid only its pure jQuery love, which makes it light weight and follows the jQuery mantra of running with the least amount of configuration.
Features
Taking advantage of the new capabilities of HTML5 and CSS3 can mean sacrificing control over the experience in older browsers. Modernizr 2 is your starting point for making the best websites and applications that work exactly right no matter what browser or device your visitors use.
Quite simply, SlickGrid is a JavaScript grid/spreadsheet component.
It is an advanced component and is going to be a bit more difficult to learn and configure, but once you realize its full potential, it will blow your mind!
Nice options and Ajax Call.
Easily position tooltips, popovers (popup) or anything with just a line of code. Used by Bootstrap 4.
https://github.com/mar10/fancytree
https://github.com/mar10/fancytree/wiki
https://wwwendt.de/tech/fancytree/demo/#sample-ext-glyph-svg.html
http://dojotoolkit.org/reference-guide/dijit/Tree.html
The trees we see in User Interfaces help sort out long, hierarchical lists. A file system is the classic example, with Windows using it in Explorer. The Dijit tree widget is like that. Dojo makes easy trees easy, and hard trees possible.
http://prototype-window.xilinus.com/index.html
A prototype based windows framework. Fourni le moyen de faire des fenêtres, modal ou non.
Light and responsive lightbox (popup) script.
Automatic image gallery from images in popup on html page.
http://lokeshdhakar.com/projects/lightbox2/
Fonctionne avec attribut data-lightbox=“image-1”
sur un lien a
.
Lightweight, accessible and responsive lightbox (html popup).
jCarousel is a jQuery plugin for controlling a list of items in horizontal or vertical order. It provides a full-featured and flexible toolset for navigating any HTML based content in a carousel-like fashion.
the last carousel you'll ever need.
Mozilla PDF.js is a Portable Document Format (PDF) viewer that is built with HTML5.
An open source Flash™ runtime written in pure JavaScript with SVG.
Comment: ça déchire !! Par contre, comme d'hab ça ne fonctionne pas avec IE 8 …
http://sztanko.github.io/crosslet/
Crosslet is a free small (22k without dependencies) JavaScript widget for interactive visualisation and analysis of geostatistical datasets. You can also use it for visualizing and comparing multivariate datasets.
It is a combination of three very powerful JavaScript libraries:
Crosslet also supports TopoJSON, a GeoJSON extension that allows to present geometry in a highly compact way.
Crosslet is written in CoffeeScript and uses less for styling.
SVG animation
http://mbostock.github.com/d3/
Data-Driven Documents
D3.js is a small, free JavaScript library for manipulating documents based on data.
http://jsxgraph.uni-bayreuth.de/
Interactive Geometry, plotting, visualization
JSXGraph is a cross-browser library for interactive geometry, function plotting, graphs, and data visualization in a web browser. It is implemented completely in JavaScript and uses SVG and VML. JSXGraph is easy to embed and has a small footprint: only about 55 KB if embedded in a web page. No plug-ins are required! JSXGraph uses the JavaScript libraries/frameworks Prototype or jQuery.
SVG-edit is a fast, web-based, Javascript-driven SVG editor that works in any modern browser. SVG-Edit does not work with IE7, must add Google Chrome Frame.
Raphaël is a small JavaScript library that should simplify your work with vector graphics on the web. Raphaël uses the SVG W3C Recommendation and VML as a base for creating graphics. This means every graphical object you create is also a DOM object, so you can attach JavaScript event handlers or modify them later.
The JavaScript InfoVis Toolkit provides tools for creating Interactive Data Visualizations for the Web.
A Versatile and Expandable jQuery Plotting Plugin!
Simple yet flexible JavaScript charting for designers & developers
The open source JavaScript graphing library that powers plotly.
https://frappe.github.io/charts/
Flot is a pure Javascript plotting library for jQuery. It produces graphical plots of arbitrary datasets on-the-fly client-side. The focus is on simple usage (all settings are optional), attractive looks and interactive features like zooming and mouse tracking.
Video.js is an open source library for working with video on the web, also known as an HTML video player.
depecrated https://www.graphdracula.net/
http://www.clipperz.com/open_source/javascript_crypto_library
Javascript Crypto Library
http://crypto.stanford.edu/sjcl/
SJCL is small but powerful. The minified version of the library is under 6.4KB compressed, and yet it posts impressive speed results.
SJCL is secure. It uses the industry-standard AES algorithm at 128, 192 or 256 bits; the SHA256 hash function; the HMAC authentication code; the PBKDF2 password strengthener; and the CCM and OCB authenticated-encryption modes. Just as importantly, the default parameters are sensible: SJCL strengthens your passwords by a factor of 1000 and salts them to protect against rainbow tables, and it authenticates every message it sends to prevent it from being modified. We believe that SJCL provides the best security which is practically available in Javascript. (Unfortunately, this is not as great as in desktop applications because it is not feasible to completely protect against code injection, malicious servers and side-channel attacks.)
Angular JS and Twitter Bootstrap
AlpineJs permet de créer/gérer des composants falicement avec Javascript sans se lancer dans une SPA, très léger (<10ko gzippé et minifié) et n'utilise pas de DOM virtuel. Sa syntaxe est similaire à VueJS. C'est un bon outil pour remplacer jQuery et moins complexe que VueJs / React / Angular.
Vue.js implémente le modèle Modèle-Vue-VueModèle (MVVM), des directives pour agir sur le DOM, la syntaxe mustache et des filtres pour la mise en forme.
Tutos FR:
Tuto EN:
Tips:
Voir aussi:
/wp-json/wp/v2/posts?filter[orderby]=date
A Facebook & Instagram collaboration.
Super-powered by Google. Code licensed under the The MIT License.
About html form:
Accessibility:
Mobile:
Simplify dynamic JavaScript UIs with the Model-View-View Model (MVVM) pattern.
http://developer.yahoo.com/yui/
The Yahoo User Interface (YUI) Library is a set of utilities and controls, written with JavaScript and CSS, for building richly interactive web applications using techniques such as DOM scripting, DHTML and AJAX. YUI is available under a BSD license and is free for all uses. YUI is proven, scalable, fast, and robust. Built by frontend engineers at Yahoo! and contributors from around the world, it's an industrial-strength JavaScript library for professionals who love JavaScript.
MooTools is a compact, modular, Object-Oriented JavaScript framework designed for the intermediate to advanced JavaScript developer. It allows you to write powerful, flexible, and cross-browser code with its elegant, well documented, and coherent API.
http://gimme.stchur.com/about.html
What is Gimme?
Gimme is a light-weight, speed-focused, ECMAScript (or Javascript if you prefer) Library, designed to make your life simple!
Gimme's prominent features:
Prototype is a JavaScript Framework that aims to ease development of dynamic web applications.
Featuring a unique, easy-to-use toolkit for class-driven development and the nicest Ajax library around, Prototype is quickly becoming the codebase of choice for web application developers everywhere.
script.aculo.us provides you with easy-to-use, cross-browser user interface JavaScript libraries to make your web sites and web applications fly.
What's inside? animation framework, drag and drop, Ajax controls DOM utilities, and unit testing.
It's an add-on to the fantastic Prototype framework.
<note>Attention a laisser de l'information pour les moteurs de recherche …</note>
Une façon simple d'avoir du code propre sans ajouter un nouveau moteur de template (no “black box”, quick, and simple) :
templates = { contact_details : function( data ){ return "<p>" + "Name: " + data.name + "<br>" + "Phone: " + data.phone + "<br>" + "email: " + data.email " + "</p>"; }
Que l'on utilise avec jQuery:
$(this).append( templates.contact_details(p) );
ou pour des instances multiples:
var output = ''; $.each( persons, function(p){ output+= templates.contact_details(p); });
http://javascriptcodebehind.codeplex.com/
Séparation du Javascript et du HTML sur le principe de CodeBehind d'ASP.
“The aim of this paper is to present a technique for separating the JavaScript code of a HTML page. The result is a .js file that contains all the logic of programming of the page. It's the same idea of code-behind files in ASP.NET, defining the concepts: the server code-behind file (.cs, for example) and client code-behind file (.js).”
Cappuccino is an open source framework that makes it easy to build desktop-caliber applications that run in a web browser.
http://jsclientpages.codeplex.com/
“JavaScriptClientPages is a cross-browser, cross-platform tool, which makes dynamic client-side content generation as easy as it is on the server side with technologies like ASP.net, PHP, Ruby on Rails, etc.. Each JavaScritpt Client Page is a complete XHTML page with embedded JavaScript code, as well as custom output tags that make it possible to create clean XHTML templates with advanced presentation logic while eliminating the drudgery of writing custom DOM manipulation code or innerHTML construction.”
JSCP Code Sample :
<table> <thead> <tr> <th>Code</th> <th>Name</th> <th>Price</th> </tr> </thead> <tbody> <!-- XML-based presentation logic tags. Similar to: ASP.net, JSP with taglibs, JSF --> <js:forEach collection="items" item="item"> <tr> <td class="code">Item #<js:Text value="item.code" /></td> <td><js:output value="items.name" /></td> <td><js:output value="MyLib.formatCurrency(text(item.price));" /></td> </tr> </js:forEach> </tbody> </table>
Logic-less templates with JavaScript.
http://mustache.github.com/, https://github.com/janl/mustache.js/
var view = { title: "Joe", calc: function() { return 2 + 4; } } var template = "{{title}} spends {{calc}}"; var html = Mustache.to_html(template, view);
Quelques lignes de Javascript pour un simple moteur de template côté client, c'est fun
Simple and ultra-fast templating tool to generate HTML from JSON data.
jQote2 is the second major release of jQuery’s most powerful and versatile client-side templating engine. Version 2 now incorporates a faster and more accurate parsing/conversion part that does away with its predecessor’s shortcomings in escaping quotes and multiline support.
jQote (pronounced like Star Trek’s Chakotey) is basically a rewrite of John Resig’s awesome JavaScript Micro-Templating utility. I took his code and ported it to jQuery, overhauled the parsing / conversion part and extended it’s functionality to minimize everyone’s coding efforts.
http://aefxx.com/jquery-plugins/jqote/ ⇒ jQote2
<script type="text/html" id="template"> <![CDATA[ <p class="greetings"> Hello <%= this.name %>, how are you doing? May I offer you <% this.is_starving() ? %> some tasty peasant? <% : %> a refreshing Singha? <% ; %> </p> ]]> </script>
For web application developers, the 'JavaScript Templates
' engine from TrimPath is a lightweight APL / GPL open-source component that lets you have template-based programming (like PHP/ASP/JSP) while running in a web browser.
'JST
' engine is written entirely in standard JavaScript.Build your own modern, brilliantly rich web applications (like GMail/OddPost/Bloglines) with JavaScript Templates.
Jaml is a small but delightful way of rendering HTML using JavaScript. It uses a simple DSL-like syntax to DRY up your code. There are only 2 steps - registering a template and rendering it. Let's look at something simple first. On the left of each example is the source code, and on the right the rendered output.
EJS cleans the HTML out of your JavaScript with client side templates. After EJS gets its rubber gloves on dirty code, you'll feel organized and uncluttered.
MicroTemplate is a javascript template engine based on the john resig's microtemplate engine.
Template syntax is very easy, usefull and powerfull because you can use normal javascript.
GWT App is a HTML templating for GWT based on JSP and similar to use like UiBinder. HTML templates don't need to be compiled together with GWT application and can be changed by web designer at any time without GWT application recompilation.
GWT App provides several features and benefits like:
http://www.html5rocks.com/fr/features/storage
SQLite compiled to javascript.
sql.js is a port of SQLite to JavaScript, by compiling the SQLite C code with Emscripten. no C bindings or node-gyp compilation here.
SQLite is public domain, sql.js is MIT licensed.
LUNR.js a simple full-text search in your browser.
4k
256b
What determines that a script is long-running ?
Note that the IE limit of 5M instructions was first put in place back in 1997 as part of IE3 and, I believe, has not been changed in that time.
The slow script error does not seem to be limited to a single script. Run a script once with a button click and there is no error. Run it again by clicking the button a second time and you get the error. So the counter seems to be cumulative in some cases, not limited to a single script. The script in question is a simple for-loop intended to trigger the slow script error, so the instructions per click should be identical.
A way to asynchronously process JavaScript arrays to avoid locking up the browser (and further, to avoid displaying the long-running script dialog) : Timed array processing in JavaScript
Ne pas utiliser des méthodes du genre is_ie, is_opera, is_win,is_nav2, is_nav3… Mais plutôt tester chaque fonctionnalité:
if (document.body && typeof(document.body.offsetHeight) == 'number') { height = document.body.offsetHeight; } else if (typeof(window.innerHeight) == 'number') { height = window.innerHeight; } else { height = 0; }
Voir Browser Detection and Cross Browser Support
Et sur la page The Ultimate JavaScript Client Sniffer, Version 3.03 il est bien écrit que cette méthode est obsolète.
La méthode suivante n'est pas fiable après depuis le HTML 3.2 et encore moins après le HTML4+ car les dernières génération se basent sur l'attribut “type” et non pas language.
<script type="text/javascript"> var jsver = 1.0; </script> <script language="Javascript1.1"> jsver = 1.1; </script> <script language="Javascript1.2"> jsver = 1.2; ... <script type="text/javascript"> document.write('<p><b>Javascript version ' + jsver + ' supported<\/b><\/p>'); </script>
Donc encore une fois il faut se baser sur les fonctionnalités, et donc voir les changelogs et “What's new” des spécifications de Javascript.
http://jsfiddle.net/Fractaliste/LvsYc/1669/
<form id="form1" runat="server"> <input type='file' id="imgInp" /> <img id="target" src="#" alt="your image" /> </form>
function readURL(input) { if (input.files && input.files[0]) { var reader = new FileReader(); reader.onload = function (e) { $('#target').attr('src', e.target.result); } reader.readAsDataURL(input.files[0]); } } $("#imgInp").change(function(){ readURL(this); });