JavaScript for Line of Business Applications
606.6K views | +4 today
JavaScript for Line of Business Applications
Keeping track of current JavaScript Frameworks that help design your clientside Business Logic Layers.
Curated by Jan Hesse
Beam to my Inbox:
Your new post is loading...
Your new post is loading...

Popular Tags - Filter using the Funnel

Scoop.it!

AngularJS Architecture, Part 2: Understanding Modules

AngularJS Architecture, Part 2: Understanding Modules | JavaScript for Line of Business Applications | Scoop.it

As you have probably figured out by now, Angularjs has quite a few tricks up its sleeve that make it a unique and different kind of framework to work with. It draws architectural principles and design patterns from native application programming languages and applies them to Javascript. Of course, this is still Javascript we’re talking about, so the implementation of such patterns sometimes require a bit of creativity. For example, to accomplish object instantiation, instead of having a constructor method like you would see in a native language class, Angularjs uses modules to declaratively describe how an application should be instantiated and bootstrapped. A module configures the Injector by specifying the services, directives, filters, and any other configuration information for the application at runtime.

Jan Hesse's insight:

Part 1: http://danorlando.com/angularjs-bootstrap-lifecycle-general-overview/

No comment yet.
Scoop.it!

Animating route transitions in ember.js

Animating route transitions in ember.js | JavaScript for Line of Business Applications | Scoop.it

Animations aren’t just eye candy - they make your app feel faster. Unfortunately Ember still hasn’t settled on a standard method for animations.

Ember has been placing emphasis on the URL as the central “state” of a web application. There’s a great talk by Tom Dale talking about the importance of the URL. The amazing work done on the new router by Alex Matchneer means we now have a promise based system for transitioning between routes and loading models, which makes it a nice destination for adding animations.

My solution is to add a promise hook to both the entering and exiting of a route. Include this code after including ember.

No comment yet.
Scoop.it!

HTML5: Using IndexedDB with WebGL and Babylon.JS

HTML5: Using IndexedDB with WebGL and Babylon.JS | JavaScript for Line of Business Applications | Scoop.it

In this article, I’d like to share everything I’ve been learning while developing the support for IndexedDB inside our 3D WebGL Babylon.JS game engine. Indeed, since 1.4.x, we’re now supporting storing & loading the JSON scenes containing our 3d meshes and their .PNG or .JPG textures as blobs from IndexedDB.

This article is built around my own experience on this topic. It’s based on the way I’ve solved the various issues I have encountered while working with IDB. You’ll then find someexplanations & tips on what you must pay attention to when you’ll work with IndexedDB. I will also share how and why we’re using it inside our 3d WebGL engine. Still, this article may be helpful for anybody looking at IndexedDB in general. 3d gaming will just serve as an illustration of its usage.

No comment yet.
Scoop.it!

Now available: ESLint v0.1.0

Today I’m excited to announce version 0.1.0 is available. This is the first alpha version that is ready for people to start using and give us feedback on. Up until this point, the tool was in a state of constant flux and I didn’t feel comfortable recommending anyone use it. I wanted to get ESLint as close to the ruleset of JSHint before deeming it ready for use, and we are finally there. We have (as best we can tell), nearly 100% coverage of the JSHint rules that don’t apply to formatting (white space and other code convention rules).

Here’s what this release gives you:
* Most of the JSHint rules (that don’t apply to formatting issues)
* New rules can be loaded at runtime
* Specification of shared settings using .eslintrc files
* Configure rules as disabled, warnings, or errors
* Output results as Checkstyle, compact, JSLint-XML, or JUnit formats
* 95% or higher code coverage for statements, branches, functions, and lines

Mickael Ruau's curator insight, November 14, 2013 5:51 PM

Un vérificateur de code javascript.

Scoop.it!

LispyScript - A javascript With Lispy Syntax And Macros!

An inherent problem with Javascript is that it has no macro support, unlike other Lisp like languages. That's because macros manipulate the syntax tree while compiling. And this is next to impossible in a language like Javascript.

In LispyScript we write Javascript in a tree structure. If you know Javascript and a Lisp like language, then using LispyScript will be a breeze. Even if you don't know a Lispy Language, all you need to learn is to write code in a tree structure.

No comment yet.
Scoop.it!

Client Side Web Application primer

Client Side Web Application primer | JavaScript for Line of Business Applications | Scoop.it

I plan to share my experiment with client side application and MVC backend. In this sample, as many other web site before I use many 3rd party libraries (hint: look at README / package list: EntityFramework (Extended), jQuery, Knockout, chosen, bootstrap,datatables). But I don’t plan to dwell much on them in this post. Instead I want to focus on how I use T4 Templates to generate strongly WebAPI server proxy in TypeScript and use Knockout to drive the UI. With a little bit extra on WebAPI and SQL.

This post is intended for web developer having basic to medium knowledge of MVC, Javascript, jQuery.ajax(), TypeScript. I am not going to explain the whole application but just the challenging parts and the solutions I implemented. For the rest there is the source code.

My sample application (largely inspired from work needs) is a 3 pages application. A first page manage dynamic questionnaire (with dynamic groups of dynamic questions), a second page can answer those questionnaires and a third can query them.

No comment yet.
Scoop.it!

Testing Durandal apps made easy

Testing Durandal apps made easy | JavaScript for Line of Business Applications | Scoop.it

Hi there,

The today’s post is targeted to a very dedicated audience, so let’s see if the following is for you.

* You belong to the growing number of Durandal developer?

* You have a need to make your apps better?

* You don’t know yet how to test a Durandal app?

If you answered one or multiple of these questions with a yes, read on.

Hey, even you answered the last two questions with a no read on to see if Grunt can make your life easier. When you haven’t heard of Grunt yet, head over to smashingmagazine for a nice Grunt intro.

No comment yet.
Scoop.it!

Obey and Report – A JavaScript Event Emitter Pattern

Obey and Report – A JavaScript Event Emitter Pattern | JavaScript for Line of Business Applications | Scoop.it

The event emitter pattern was popularized by Node and is made available in the browser by libraries such as EventEmitter2. In practice, I haven’t seen a lot of use of event emitters in client-side applications, but lately I’ve been applying it more and more in my code. Here, I’ll introduce a modular approach to client-side development I didn’t invent, but which I decided to name anyway.

No comment yet.
Scoop.it!

CuttySSark - use evented CSS selectors

CuttySSark - use evented CSS selectors | JavaScript for Line of Business Applications | Scoop.it
A lightweight polyfill adding support for JS event triggering and matching in stylesheets using standard CSS2 selectors.

Often events are registered using JavaScript for the sole purpose of updating styles. Especially with the advent of CSS animations and other CSS3 syruppy sweetness, simple style changes can hold huge impact for user experience. The goal of CuttySSark is to allow the front-end developer to write compliant CSS that interacts seamlessly with the JS event model.And it's just a weeny little JS file.

Cutty pretty much only does two things.

Registers events to apply a style block.Allows remote triggering by one DOM element on another.
No comment yet.
Scoop.it!

Productive Out-of-the-Box with Ember.js

Productive Out-of-the-Box with Ember.js | JavaScript for Line of Business Applications | Scoop.it
Anthony Bull overviews some of the tools that help being productive with Ember.js, providing details on Yeoman.
No comment yet.
Scoop.it!

Creating an AngularJS Directive from one of your existing plugins/scripts

Creating an AngularJS Directive from one of your existing plugins/scripts | JavaScript for Line of Business Applications | Scoop.it

Writing scripts for your websites or web apps is often a simple process, you write your script, concatenate the file into your main scripts file and it gets pushed into the DOM. Not much to it, but when it comes to AngularJS, they believe in something slightly different...

No DOM manipulation should be carried out inside a Controller, the Controller is where most of your magic happens, a communications channel between your Model data and the browser. It can be tempting to simply whack in an existing script in there (as it'll work just fine), but this goes against Angular's principles.

So here's how to migrate one of your existing scripts or plugins across into a tightly coded AngularJS directive, this also makes code readability and reuse ultra-efficient, as Directives take the strain of repetative code out the window.

Directives are Angular's answer to Web Components 'Shadow DOM' but are compatible in all browsers (not just cutting edge HTML5 supporting ones) - bringing you the power of the future technology, today. Shadow DOM injects new content based on the element, has it's own CSS and JavaScript scope and introduces some incredible behaviour mechanisms, and this is what Directives mimic to bring you this technology today.

No comment yet.
Scoop.it!

Using Track-By With ngRepeat In AngularJS 1.2

Using Track-By With ngRepeat In AngularJS 1.2 | JavaScript for Line of Business Applications | Scoop.it

With the release of AngularJS 1.2 earlier this week, I have to say that the feature about which I am most excited is the "track by" augmentation for ngRepeat. This feature allows you to associate a JavaScript object with an ngRepeat DOM (Document Object Model) node using a unique identifier. With this association in place, AngularJS will not $destroy and re-create DOM nodes unnecessarily. This can have a huge performance and user experience benefit.

As I've blogged about before, when AngularJS renders an ngRepeat list, it injects an expando property - $$hashKey - into your JavaScript objects. It then uses this $$hashKey to associate your objects with the rendered DOM nodes. In the past, I've the hashKeyCopier library to manually manage these $$hashKey's such that I could updated the rendered collection with live data without causing unnecessary (and sometimes harmful) DOM changes.

No comment yet.
Scoop.it!

Choosing the right JavaScript library/framework/toolkit for our project

Tips & directions what to look for in a framework/lib/toolkit before making the choice.
No comment yet.
Scoop.it!

jQuery Performance Tips Cheat Sheet

jQuery Performance Tips Cheat Sheet | JavaScript for Line of Business Applications | Scoop.it

I was hunting for jQuery performance tricks for a while to tune my heavy dynamic web app. After digging in a lot of articles decided to make a list of the best common performance tips. I also built a handy jQuery Performance Cheat Sheet that can be printed or placed on my desktop.

* Selectors performance tips
* DOM manipulation performance tips
* Events performance tips
* Testing jQuery
* General jQuery performance tips


No comment yet.
Scoop.it!

MVVM in BackboneJS using Backbone.Stickit

MVVM in BackboneJS using Backbone.Stickit | JavaScript for Line of Business Applications | Scoop.it

I have been looking into various design patterns and trying to architect client side applications using it. More often than not the MVC pattern fits the requirement in most of the applications. However, I have found myself using MVVM (Model View - View Model) pattern along with MVC. I use MVVM pattern particularly when I have to maintain the state of the model on the client side. AngularJS provides great support by allowing you to extend the markup and tying the model right within the view (the markup). It also provides components that can be used to structure the application the MVC way and hence it's appropriately termed as MVW or MV* framework. However, I use BackboneJS in most of my applications and I have been able to maintain the state of the model using the Backbone.Stickit plugin.

No comment yet.
Scoop.it!

Why I am switching to promises

Why I am switching to promises | JavaScript for Line of Business Applications | Scoop.it

I'm switching my node code from callbacks to promises. The reasons aren't merely aesthetical, they're rather practical:

Promises are throw-safe. If an error is thrown in one of the .then callbacks, only that single promise chain will die. I can also attach error or "finally" handlers to do any clean up if necessary - transparently! The process will happily continue to serve the rest of my users.

Promises are now part of ES6
Yes, they will become a part of the language. New DOM APIs will be using them too. jQuery already switched to promise...ish things. Angular utilizes promises everywhere (even in the templates). Ember uses promises. The list goes on.

But you said promises are slow!
Yes, I know I wrote that. But I was wrong. A month after I wrote the giant comparison of async patterns, Petka Antonov wrote Bluebird. Its a wicked fast promise library, and here are the charts to prove it...

No comment yet.
Scoop.it!

Assertion Counting in Mocha

Test plans help in situations where you want to put assertions inside asynchronous events. For example, if you’re testing a web application and it makes HTTP requests in the test cases, but you also intercept events that indicate various lifecycle events. These could be things like ensuring a notification email was sent when a user signs up, and also checking that their account was saved to the database.

In Mocha, such a test might look like this...

No comment yet.
Scoop.it!

Writing a Fullstack Application with Javascript

Writing a Fullstack Application with Javascript | JavaScript for Line of Business Applications | Scoop.it

Writing apps should be fun. This is a statement I try to keep in mind when approaching any application development. When I first realised that a full stack of Javascript can be used to create an application I was very happy, since for me coding in Javascript is a lot of fun. I was soon quite eager to neglect the traditional Java server-side + Javascript client, giving up the Java server side "bliss" and the constant context switching, in favor of a full stack of Javascript whenever I could.

On October 29th 2013 I gave a talk at the "Javascript.everywhere" meetup event, in which I presented the development route of Youtube Remote Control Application with a "slave" player using Javascript stack all over (NodeJS, Socket.IO, ExpressJS, AngularJS, MongoDB). I'm pleased to share the presentation and video.

No comment yet.
Scoop.it!

Write Better, Flexible Code By Using Composition In Angular.js

There is an ocean of frameworks out there for single page javascript applications. But one of them stands out in particular. Not only because it does things differently, but it also encourages you to do it differently. That framework is Angular.js

In Angular.js, every object (controller, service or factory) you create is a plain-old-javascript-object (POJO). The importance of this little feature can very easily be undermined by features of the contending frameworks. But it can only be understood by diving a little deeper into POJOs. Long story short: they are little functions that are independent, do not inherit from another object and are easily testable and scalable. May not sound much right now, but this is really important for decoupling logic in a large scale application. Which brings me to the second point.

No comment yet.
Scoop.it!

Patterns for Knockout.js — Proxy Object

Lately, I’ve been looking into patterns in Knockout that will allow separation between view- and backend-related code. I’ve been trying to find methods of transparently communicating to a server API when relevant view model properties change, without explicitly concerning the view code.

This post describes one of the solutions I’ve used for my current project, which I will name proxy objects, lacking a better name. We’ll look into how to set up observable objects that are automatically persisted by posting to an API, and thus decoupling it from the view model.

We’re going to build something like the example below, where the server is notified as the user changes data in the fields. In the right hand column we’ll log “server” (a.k.a console.log) calls to our API. Edit the fields to see what calls are made.

No comment yet.
Scoop.it!

Defer DOM Tree Binding In AngularJS With Delayed Transclusion

Defer DOM Tree Binding In AngularJS With Delayed Transclusion | JavaScript for Line of Business Applications | Scoop.it

When you start out with AngularJS, everything just "works." It's pretty freakin' awesome! But, as your applications get more complex, and your user interfaces (UIs) get more layered, the rendering of an AngularJS view can start to get slower. In particular, once you hit a critical mass of 2,000+ bindings [I'm told], processing time can become palpable. As such, I've been experimenting with ways to keep my UIs rich while keeping my processing time under control. My latest experiment involves delaying the binding of rarely-used DOM trees such that they don't have to be linked until they are needed.

No comment yet.
Scoop.it!

AngularJS: Learning the First Steps to Build a Music Discovery App

AngularJS: Learning the First Steps to Build a Music Discovery App | JavaScript for Line of Business Applications | Scoop.it

So my first experiences with AngularJS were pretty good; I was interested and motivated and excited to start my placement with an interesting and exciting company using the newest technologies. “This will be fun”, I thought to myself. Cut to a week later and I was still trying to make sense of the first task I was asked to work on for seevl. “This is not fun”, I thought to myself.

The accepted wisdom when it comes to AngularJS is that its learning curve is less curvy and more hockey-stick shaped, i.e. it starts off gently and you think everything is going great until you crash face-first into a gigantic brick wall which seems to rise infinitely high above you. My first reaction, and I’m sure I’m not alone here, was to throw myself against the wall again and again until I was worn out and broken. Of course, the only sensible approach is to take a step (or maybe a few hundred) backwards and eventually you’ll start to see the top of the wall and maybe even see a few obvious foot- and hand-holds that might help you on the climb to the top.

No comment yet.
Scoop.it!

Opa & AngularJS by Adam Koprowski

Opa & AngularJS by Adam Koprowski | JavaScript for Line of Business Applications | Scoop.it

A short introduction to two modern approaches to developing web-apps: Opa and AngularJS.

* Modules

* Types

* Backend

* etc.

No comment yet.
Scoop.it!

Isomorphic JavaScript: The Future of Web Apps

Isomorphic JavaScript: The Future of Web Apps | JavaScript for Line of Business Applications | Scoop.it

The bulk of the application logic (views, templates, controllers, models, internationalization, etc.) lives in the client, and it talks to an API for data. The server could be written in any language, such as Ruby, Python, or Java, and it mostly handles serving up an initial barebones page of HTML. Once the JavaScript files are downloaded by the browser, they are evaluated and the client-side app is initialized, fetching data from the API and rendering the rest of the HTML page.

This is great for the user because once the app is initially loaded, it can support quick navigation between pages without refreshing the page, and if done right, can even work offline.

This is great for the developer because the idealized single-page app has a clear separation of concerns between the client and the server, promoting a nice development workflow and preventing the need to share too much logic between the two, which are often written in different languages.

No comment yet.
Scoop.it!

What can I do with a GridPanel in ExtJS

What can I do with a GridPanel in ExtJS | JavaScript for Line of Business Applications | Scoop.it

I have to develop a lot of applications in my web app and I see that grid component of ExtJS may fit in. However, I am not aware of what all things I can do with the
- off the shelf available framework pieces
- available plug-ins in the marketplace and
- custom development through my own developers

This is a typical question that we hear from the business users who wants to design an application by keeping the framework’s capability in perspective. In this article I have tried to put the list of stuff you can do with grid and hopefully that shall enable you to take advantage of the beauty of ExtJS.

 

What are the available options?

In this section I will be taking you through some of the commonly seen usage of ExtJS grid panel. While covering all the capabilities of grid may not be possible, I am sure it will be helpful for the business users who want to understand what he / she can do with this component of ExtJS. This article needs continuous improvement to make this further useful. I am looking forward to feedback and suggestion to make this article even more useful.

No comment yet.