background preloader

Javascript

JSbooks - free javascript books
DevDocs
javascript resources

Javascript Flavors

mikeaddison93/angular.js · GitHub
Bower
unnamed pearl
Object.create() Object.create() The Object.create() method creates a new object with the specified prototype object and properties. SyntaxEdit Object.create([, ]) Parameters proto The object which should be the prototype of the newly-created object. propertiesObject Optional. Throws Throws a TypeError exception if the proto parameter isn't null or an object. ExamplesEdit Classical inheritance with Object.create() Below is an example of how to use Object.create() to achieve classical inheritance. function Shape() { this.x = 0; this.y = 0;} Shape.prototype.move = function(x, y) { this.x += x; this.y += y; console.info('Shape moved.');}; function Rectangle() { Shape.call(this); } Rectangle.prototype = Object.create(Shape.prototype); Rectangle.prototype.constructor = Rectangle; var rect = new Rectangle(); console.log('Is rect an instance of Rectangle?' If you wish to inherit from multiple objects, then mixins are a possibility. Using propertiesObject argument with Object.create() PolyfillEdit if (typeof Object.create ! See alsoEdit
Naked JavaScript

JavaScript_Enlightenment.pdf
Understanding Design Patterns in JavaScript Today, we're going to put on our computer science hats as we learn about some common design patterns. Design patterns offer developers ways to solve technical problems in a reusable and elegant way. Interested in becoming a better JavaScript developer? Republished Tutorial Every few weeks, we revisit some of our reader's favorite posts from throughout the history of the site. Solid design patterns are the basic building block for maintainable software applications. A design pattern is a reusable software solution Simply put, a design pattern is a reusable software solution to a specific type of problem that occurs frequently when developing software. patterns are proven solutions to software development problems patterns are scalable as they usually are structured and have rules that you should follow patterns are reusable for similar problems We'll get into some examples of design patterns further in to the tutorial. Creational patterns focus on ways to create objects or classes. Understanding Design Patterns in JavaScript
Today we have decided to showcase a 'map' of the current state of web animation by compiling highly regarded libraries, frameworks and plugins based on their versatility and performance. Infographic 1: The Map of Web Animation The infographic is divided into three sections, the first part is a selection of a few of the most comprehensive animation libraries which offer up all the tools one could ever wish for from easing functions and callbacks to timing control, not to mention the generic animation functions we have come to expect. Infographic 2: List of Tools The second section is dedicated to the various methods for animating UI elements and any others objects in the DOM like scroll animation, parallax, sprites, 3D transformations, physics engines, and transitions. Infographic 3: Performance Tips Last but not least, the third section lays out some basic performance tips to help choose between CSS or Javascript-based animation depending on the requirements of any given project. Web Animation Infographics: A Map of the Best Animation Libraries for JavaScript and CSS3 plus Performance Tips Web Animation Infographics: A Map of the Best Animation Libraries for JavaScript and CSS3 plus Performance Tips
15 Beautiful Text Effects Created with CSS Beautiful text or typography will make your design look attractive. In web design, CSS helps to give style to design including various effects in text or typography. With CSS, you can use clipping and add animation to text to spice things up a little. And to illustrate this, we have collected 15 stunning and cool text effects that are made possible with CSS (some with a little help from Javascript codes). For more things you can do with CSS, check out: Elastic stroke Animation Yoksel animates the stroke of the text with a cool color scheme. SVG Glitch Want to make effects that look like a broken analog TV? Shop Talk logo The Shop Talk logo is recreated by Hugo using only CSS. Slashed Effect This idea by Robet Messerle gives the knife sliced effect, done with less than 70 lines of CSS. Elegant Shadow Effect Long Shadow effect comes to text, made using CSS. Foggy text effect Andreas creates an awesome cinematic foggy effect. SVG text mask Text Animation Hit The Floor Background Clip Text CSS Text-FX 15 Beautiful Text Effects Created with CSS
6 CSS Tricks to Align Content Vertically 6 CSS Tricks to Align Content Vertically Let’s talk about vertical alignment in CSS, or to be more precise how it is not doable. CSS has not yet provided an official way to center content vertically within its container. It’s a problem that probably has frustrated web developers everywhere. But not to fear, in this post, we’re going to run by you a few tricks that can help you imitate the effect. These tricks may however have limitations, and you may have to use more than one trick to complete the illusion. Recommended Reading: How To Obtain Equal Column Height With CSS 1. The first trick we are going to see here uses the position property. We will first set the position of the container element to relative, then we set the child element position to absolute. To align it vertically, move the child element position from the top, by half of the container’s height, and pull it up by half of the child element width. 2. CSS3 Transform has made it easy to put content at the center. 3. 4. 5. 6.
Web - HTML / CSS / JavaScript

Introduction To Photoshop Scripting Introduction To Photoshop Scripting Automation is useful in the work of every designer. It saves precious time on repetitive tasks and helps us solve certain problems more quickly and easily. You can automate your workflow in Photoshop with actions, which are pretty popular and which most of you already know about and use. Today, we’ll introduce you to an advanced automation technique: scripting. All you need for this is basic knowledge of JavaScript, which some of us Web designers already have. I’ve known about Photoshop scripts for years but decided to really dive in a few months ago. But first, we have to answer the obvious question. Why Do We Need Scripts? Why should we would learn to script if Photoshop already has pretty nice actions? A script is more dynamic; its behavior changes according to the parameters you input or the context of its application. Requirements Link You don’t have to be an advanced programmer to be able to write scripts; I’m just a graphic designer, like most of you. Getting Started Link Tools Link
Ps script / javascript / Batch renaming / etc

Best Photoshop Export Action Ever | Uncorked Studios Best Photoshop Export Action Ever | Uncorked Studios Recently here at Uncorked we’ve been looking at ways to optimize and improve our processes, and in reflecting on how we do things here at Uncorked, I brought up the number of times I’ve been standing over a designers shoulder and been telling them to “just press F5”. A blank stare always ensues, huh? While I’ve been using this export action for forever myself, I’ve never shared it. Shame on me. Provided here is an action set containing two actions: Layer Export (F5)Layer Export Retina (F6) After downloading and unzipping, go to your Actions palette in Photoshop and from its options pulldown, select “Load Actions...” and choose the unzipped file. So what do they do? Select any layer in your photoshop document. The “retina” version will actually prompt you a second time to save an asset. So what’s it doing under the hood? The stuff about the group nesting and flattening is very relevant and the missing key to many other people's attempts at this same thing. flare@2x.png flare.png
Introduction To Photoshop Scripting
jquery - Animate.css + Viewport Checker delay?
JavaScript-2

On scroll animations using waypoints.js and animate.css - On scroll animations using waypoints.js and animate.css - Did you ever wonder how the best themes implement on scroll animations? This tutorial will allow you to recreate the effect using the popular jquery-waypoints plugin as well as the animate.css library. On scroll animation is a technique which has gained popularity over the past several months. It suits one-page websites as well as websites with many illustrations perfectly, giving them a more dynamic appearance. However, the animations can be applied to any element as we will soon see. For this tutorial we assume the reader has some prior experience with javascript and more specifically with the jQuery library, as we will need the aid of the popular jQuery-waypoints plugin. The following example will alert the user when he scrolls on any element that has a class ‘notify’: One can pass a second argument to the waypoint function, which is an options object. In the example above we express the offset as a percentage of the viewport’s height. But what if I want staggered animations?
Detecting a "Touch Screen" Device Using Modernizr Detecting a "Touch Screen" Device Using Modernizr I’m amazed at how the mobile phone evolved over the years. Today, mobile phones are touch-enabled, can be used to surf sites like on a desktop PC, and carry a lot of handy apps to help you be more productive. When we build responsive websites that aim for mobile devices, sometimes we want to include specific and extra capabilities for users to make use of its multi-touch capability. Pin it But before that, we need to first identify if the device has support for touch interaction, and it is easy to do so with Modernizr. Check out: Getting Started with Modernizr Feature Detection with Modernizr At the Modernizr download page, ensure that the Touch Event option is selected. You can then add this Modernizr.touch in your script. It’s a basic JavaScript that will show the following popup. Furthermore, you can also use this method to load touchSwipe, a jQuery plugin for touch gestures, conditionally. The above code will test for touch capability. Final Thought
HTML Event Attributes
JavaScript events and CSS classes

curriculum/README.md at master · dev-academy-programme/curriculum
Event reference Event reference DOM Events are sent to notify code of interesting things that have taken place. Each event is represented by an object which is based on the Event interface, and may have additional custom fields and/or functions used to get additional information about what happened. Events can represent everything from basic user interactions to automated notifications of things happening in the rendering model. This article offers a list of events that can be sent; some are standard events defined in official specifications, while others are events used internally by specific browsers; for example, Mozilla-specific events are listed so that add-ons can use them to interact with the browser. Standard events These events are defined in official Web specifications, and should be common across browsers. Non-standard events Mozilla-specific events Note: those events are never exposed to web content and can only be used in chrome content context. XUL events Add-on-specific events Developer tool-specific events
Pearltrees
Add-in development best practices - Docs - Office Dev Center Effective add-ins offer unique and compelling functionality that extends Office applications in a visually appealing way. To create a great add-in, provide an engaging first-time experience for your users, design a first-class UI experience, and optimize your add-in's performance. Apply the best practices described in this article to create add-ins that help your users complete their tasks quickly and efficiently. Note: When you build your add-in, if you plan to publish your add-in to the Office Store, make sure that you conform to the Office Store validation policies. Provide clear value Create add-ins that help users complete tasks quickly and efficiently. Create an engaging first-run experience Engage new users with a highly usable and intuitive first experience. For templates that illustrate patterns that you can apply as you develop your first-run experience, see UX design patterns for Office Add-ins. Use add-in commands Apply UX design principles Optimize for touch Market your add-in
The UX design patterns for Office Add-ins project includes HTML, JavaScript, and CSS files that you can use to create the UX for your add-in. Use the UX design patterns project to: Apply solutions to common customer scenarios.Apply design best practices.Incorporate Office UI Fabric components and styles.Build add-ins that visually integrate with the default Office UI. Using the UX design patterns You can use the UX designer specifications as a guide when you create your own UX design, or you can add the source code directly to your project. To use the specifications to build a mock-up of your own add-in UI: To add the source code: Clone the UX design patterns for Office Add-ins project repo. Types of UX design patterns Generic pages Generic page templates can be applied to any page in your add-in and don't have a special purpose. First-Run experience A first-run experience is the experience a user has when they open your add-in for the first time. Notifications General components UX design patterns - Docs - Office Dev Center
Office Add In Javascript

HTML5, CSS, y JavaScript

Color Picker — HTML Color Codes Analogous Complementary Triadic Tetradic Analogous Neutral Shades Tints Tones Color Picker Use the color picker by clicking and dragging your cursor inside the picker area to highlight a color on the right. Color Harmonies Color harmonies are particularly pleasing combinations of two or more colors derived from their relationship on a color wheel. Complementary colors Colors that are directly opposite one another on the color wheel are known as complementary colors. Triadic colors Triadic harmonies consist of three colors equidistant from one another on the color wheel. Tetradic colors Tetradic color harmonies are formed by two sets of complementary colors 60 degrees apart on the color wheel. Analogous colors Analogous harmonies are created by selecting the colors directly adjacent to a chosen color. Neutral colors Neutral schemes, like analogous harmonies, are formed by taking the colors on either side of a chosen color but at half the distance. Color Shades, Tints and Tones
Developer Network
HTML Table Style Generator by eli geske
ryanmcdermott/clean-code-javascript: Clean Code concepts adapted for JavaScript
Spherical Worlds by not important on CodePen In the previous articles of this series, textures have been generated that are only suitable for 2D uses. They suffer from distortion issues, evident in attempts to use them for spherical or toroidal shapes. This article will describe a method of subdividing a sphere into equally sized shapes and texturing these sections, leading to a planet without distortion. Below is an example of the type of spherical world that can be generated with the method described in this post. Notice that it does not suffer from distortion at any point on its surface. The level of details is completely controllable from the code, allowing for very large and detailed planets, though they may require much more time to generate. The 2D terrain algorithm described in previous posts in this series isn't meant for spherical mapping, it struggles with distortion issues. The pen below demonstrates the uneven projection issue. Dividing a sphere into squares will not work, they just can't be the same size.
JavaScript Start-up Performance – Dev Channel – Medium As web developers, we know how easy it is to end up with web page bloat. But loading a webpage is much more than shipping bytes down the wire. Once the browser has downloaded our page’s scripts it then has to parse, interpret & run them. In this post, we’ll dive into this phase for JavaScript, why it might be slowing down your app’s start-up & how you can fix it. Historically, we just haven’t spent a lot of time optimizing for the JavaScript Parse/Compile step. Let’s focus on some of the main phases. What slows our web apps from booting up? Parsing, Compiling and Executing scripts are things a JavaScript engine spends significant time in during start-up. Start-up times matter for performance-sensitive code. Parse and Compile have also been highlighted as a bottleneck by a number of large sites & frameworks you may be using. As we move to an increasingly mobile world, it’s important that we understand the time spent in Parse/Compile can often be 2–5x as long on phones as on desktop.
Stop Writing Slow Javascript - I Like Kill Nerds
JavaScript!

php function call using javascript
JavaScript Best Practices Part 1 · Thinkful Programming Guides
Javascript and Java Frameworks

The 7 Best Java Frameworks for 2016
Java vs. JavaScript Build Tools – Thomas Uhrig
What are the major differences between Java, AngularJS, and JavaScript and Node JS? - Quora
Tableau JavaScript API
JavaScript API Tutorial
JavaScript Jquery

javascript fevrier

maps javascript

HTML, CSS, PHP, Javascript, XML, Web Service y SOAP

JavaScript by @jerrywestfall _bak

JavaScript - jQuery