JavaScript for Line of Business Applications
606.6K views | +10 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!

Free Your Inner Voxel With Shapeways' ShapeJS

Free Your Inner Voxel With Shapeways' ShapeJS | JavaScript for Line of Business Applications | Scoop.it

With math-based art, creativity is still an important part of the equation. Of course no one can become a Bathsheba Grossman or Paul Nylander overnight, but if you're interested in learning some of the techniques that make math-based art possible (and don't have $1000 to spend on a copy of Mathematica) then Shapeways has the tool for you.

ShapeJS is an in-browser, code-based geometry generator for 3D printing. Using a JavaScript framework, ShapeJS provides a powerful system to create math-based art with voxels. What is a voxel you may ask? If you play Minecraft you may already be familiar with the underlying concept. Think of a voxel as a pixel in 3D. In fact, the name voxel is derived from the words "volume" and "pixel".

No comment yet.
Scoop.it!

Know your routes in Ember.js

Know your routes in Ember.js | JavaScript for Line of Business Applications | Scoop.it

This will be a short post about two built in Ember.js route handlers – ApplicationRoute and IndexRoute.

I’ve been building a simple application which has an /entries route. Whenever someone visits my application via root path / I wanted them to be transitioned (think redirected) to the /entries route. To do this, we’ll be using the beforeModel hook in the Route object.

Lets do it

The Route handler is the perfect place for that because it’s responsible for an application state for a given url. Since I wanted to transition from / to /entries I quickly addedthis.transitionTo(“entries”) code inside of an ApplicationRoute’s beforeModel hook.

No comment yet.
Scoop.it!

Browser Eyeballing != JavaScript Testing

Browser Eyeballing != JavaScript Testing | JavaScript for Line of Business Applications | Scoop.it
Stop eyeballing your UI in a browser to test your JavaScript code - that doesn't count. While many developers have embraced testing in their server side code using TDD, fewer test their front end JavaScript code in the same way (or in any way), and even fewer of those use any kind of automation. This talk will guide attendees on how to write testable JavaScript code, how to write tests for that code, and some solutions for automating the process.


What are we talking about?
* Writing testable JavaScript code
* Using a testing framework
* Automation
* Cross-browser testing

No comment yet.
Scoop.it!

Thoughts on debugging JavaScript, part one

Thoughts on debugging JavaScript, part one | JavaScript for Line of Business Applications | Scoop.it

Spending the past few months becoming familiar with a large and complex JavaScript codebase has been a learning experience. I have had a few tearing-my-hair-out moments of frustration, but I've also become a much more systematic debugger. In the hopes it might be helpful, and also to clarify these things for myself, here are some notes on the topic.

It turns out I have a lot of feelings about browser devtools, so that's going to be Part One. Part Two will be less specific to debugging JavaScript in the browser, and hopefully more generally applicable.

No comment yet.
Scoop.it!

SailsJS adding structure to NodeJS web applications

The beautiful thing about Sails is the ability to get alot of the boilerplate code generated quickly for you. This code gives you the basic nuts and bolts you would have to code by hand if you were not using a web framework with node. Sails is based on a MVC pattern heavily influenced by the Ruby on Rails framework, which is why when you define a model you get the basic CRUD functions out of the gate without writing any more code. The thing that Sails does well (never written any rails) is the ability to talk to any database that has an adapter written for you without having to change any of your code inside the app, change where the database is at along with any creds and you're off and running. 

Sails has the concept of Policies, these are something that are evaluated prior to running any code inside a controller. Me coming from a .net C# background would litter decorators on my actions inside my controllers to lock down who has access to what methods. It would look a little like this...

No comment yet.
Scoop.it!

Drag n drop with Emberjs, Part 2

This is the part 2 for the earlier post Drag and drop with Emberjs. In this post, our objective is to:

  • Update the Total cart price when a product is dropped into the cart
  • List the products added in the cart

When a product is dropped over the cart, we need some kind of array into which we’d push the record. So, lets set the line_items array in the controller to hold the cart products. Create a controller file...

Jan Hesse's insight:

http://nepalonrails.com/blog/2014/02/drag-and-drop-with-emberjs/

No comment yet.
Scoop.it!

Monads in JavaScript

Monads in JavaScript | JavaScript for Line of Business Applications | Scoop.it
Monad is a design pattern used to describe computations as a series of steps. They are extensively used in pure functional programming languages to manage side effects but can also be used in multiparadigm languages to control complexity.
No comment yet.
Scoop.it!

Why we abandoned server generated web pages

Why we abandoned server generated web pages | JavaScript for Line of Business Applications | Scoop.it

1. You’re constantly transporting state back and forth between client and server (and often neglecting to do so).

2. It’s slow, slow, and did I mention slow?
3. It’s a more complicated programming model.
4. Debugging is much more complicated.
Software Rants

No comment yet.
Scoop.it!

jide.js - Modern Javascript and HTML5 based UI control toolkit

jide.js - Modern Javascript and HTML5 based UI control toolkit | JavaScript for Line of Business Applications | Scoop.it

jide.js is an open source, MIT licensed, Javascript toolkit for developing rich, modern web applications. It features various powerful UI controls and is built around the concept of properties and data binding and enables highly efficient programming.

jide.js uses the AMD format and can be used with any AMD compatible loader such as require.js but also supports Browserify. Don't worry if you don't know what that means, we've prepared a short introduction for you.

jide.js is currently in beta state. This means that it is neither feature complete nor without bugs and that its APIs can change when necessary.

No comment yet.
Scoop.it!

Angular JS localization with Require JS i18n module

When we started working with AngularJS, one of the first non-trivial challenges we were faced with was to find a way to localize the text in our app.

We had a few basic requirements for the localization solution:

  1. Will not require any changes to my existing controllers.
  2. Will not polute the current $scope.
  3. Be able to define the desired string directly on the markup with a simple syntax.
  4. Be defined as a module that can be minified and compiled with RequireJS.

Some brief research did not produce any options we were completely satisfied with. We then considered the RequireJS i18n module. It is a very simple and elegant solution that's worked very well for me in my previous projects, so I set out to write a small module that will bridge the gap between this module and my Angular JS code and views.

No comment yet.
Scoop.it!

React Router Component

React Router Component | JavaScript for Line of Business Applications | Scoop.it

React router component allows you to define routes in your React application in a declarative manner, directly as a part of your component hierarchy.

Having routes defined as a part of your component hierarchy allows to dynamically reconfigure routing based on your application state. For example you can return a different set of allowed locations for anonymous and signed-in users.

React router component can dispatch based on location.pathname or location.hash if browser doesn't support History API.

Furthermore it provides advanced features like support for full page server side rendering, multiple routers on the same page and contextual routers.


No comment yet.
Scoop.it!

Consuming ASP.NET Web API OData Batch Update From JavaScript

Consuming ASP.NET Web API OData Batch Update From JavaScript | JavaScript for Line of Business Applications | Scoop.it

Consuming OData with plain JavaScript is a bit painful, as we would require handling some of the low-level conversions. datajs is a JavaScript library that simplifies this task.

datajs converts data of any format that it receives from the server to an easily readable format. The batch request sent is a POST request to the path /odata/$batch, which is made available if batch update option is enabled in the OData route configuration.

As seen in the last post, a batch update request bundles of a number of create put and patch requests. These operations have to be specified in an object literal. Following snippet demonstrates it with a create, an update and a patch request...

No comment yet.
Scoop.it!

browserver: a node.js HTTP server in your browser

browserver: a node.js HTTP server in your browser | JavaScript for Line of Business Applications | Scoop.it

Browserver is an exploration in simplifying application architecture, by looking at it upside-down, and turning web browsers into Internet-addressable web servers. It exposes a node.js-like API in the browser, tunnelling HTTP over WebSockets so that you don’t need to roll your own custom code to connect the various pieces of your web architecture to your end clients.

Instead, you can move the complexity of your application to the edges by making your end clients first-class HTTP servers, and then use your existing HTTP-related infrastructure to communicate with them.

No comment yet.
Scoop.it!

Ember and the future of the web

Ember and the future of the web | JavaScript for Line of Business Applications | Scoop.it

If you know me, you know it’s easy to get me talking about Ember.js. A year ago, I was deeply skeptical of developing client-side applications. Now, after spending a year shipping production applications in Ember, I believe that client-side apps represent the same generational leap that database-backed apps with Rails offered circa 2006.

Despite the title of this article, I can’t actually predict the future, but I can bet on it. And Charles and I are betting The Frontside’s future on the fact that Ember provides a foundation for creating amazing, next-generation user experiences for the web.

What server-side MVC does well (and doesn’t)

Server-side MVC frameworks rely on the classic Apple philosophy of optimizing for the 80% use case. These frameworks excel at taking a database, exposing CRUD (Create, Read, Update, Destroy) actions via HTTP, and building form-based UIs to work with these records. CRUD-oriented frameworks make it easy to build applications like blogs and contact management software.

What server-side MVC frameworks are not particularly well-suited to are user-driven, stateful UIs like you’d see in desktop apps like Word, Excel, or iTunes.

Rails, as a mature framework, has evolved a set of standard solutions to these types of problems. Generally, they involve minimizing the amount of JavaScript needed and placing as much of the burden on the server as possible.

No comment yet.
Scoop.it!

Using webcomponents in D3.js

Using webcomponents in D3.js | JavaScript for Line of Business Applications | Scoop.it

This post describes a prototype that uses Polymer webcomponents in D3.js.

Appending a single element, like a ‘rect’ to a D3 selection is straightforward. But when you want to append a more complex, nested structure to a selection, it would be nice if you could append a renderer or template. And I would find it even more comfortable if you could specify this in a structured language like xml/html. Furthermore, I would like to specify the behaviour of this renderer within the renderer itself.

I first encountered this desire when I tried to use D3 for visualizing Isotype charts. D3 maps data points to dom elements in a one-to-one relation, while Isotype maps data points to dom elements in a one-to-many relation. You can solve this by converting data points to arrays, but that feels a bit hackish.

I decided to use webcomponents.

No comment yet.
Scoop.it!

How I want to write node: stream all the things!

I wrote the async library back when Node first removed Promises from core (yes, that really was the case). Back then, I preferred to do with plain callbacks what was usually done by including third-party Promise, Future or Continuable libraries instead.

I find a certain elegance in describing complex patterns using simple parts, particularly when the parts are made composable through a common interface. In Node, and JavaScript in general, you're likely to use a combination of Promises, callbacks, Streams, Event Emitters and even ES6 Generators. To me, however, these all represent values in the future. What if we could reduce entire programs to transformations over a Stream, and have just one API to rule them all?

Well, here is my proposal, for your consideration and feedback: 
Highland, a high-level streams library

No comment yet.
Scoop.it!

Cross-browser AJAX uploads with Ember.js and mOxie

Implementing single-page web applications that work on all browsers remains a challenge. For the basic task of uploading files, you still need some sort of polyfill or library that adds support for older browsers (read IE 8 and 9, which are still in wide use).

In this tutorial I’m going to describe how to integrate one such library, called mOxie, with one client-side MVC framework, called Ember.js.

No comment yet.
Scoop.it!

On "The Future of JavaScript MVC Frameworks"

On "The Future of JavaScript MVC Frameworks" | JavaScript for Line of Business Applications | Scoop.it

This entry is a sort of "part 2" to my previous entry React Demystified. Now that I understand React better, I want to take a closer look at the blog post that motivated this quest to begin with, The Future of JavaScript MVC Frameworks. That entry advocates a vision for what MVC's of the future will look like in JavaScript, and is accompanied by some strong benchmark numbers.

The article's overall argument is that the design/architecture of most JavaScript MVC libraries today makes them slow. While they can be optimized to improve performance, a much better approach (according to the article) is to change the design of the MVC library to something that is inherently faster; a design where the optimizations fall out of the design "for free". A design that is fast by default. This is the claim that I want to take a deeper look at and evaluate in detail.

I want to go deeper because the form of the argument -- the idea that a fundamentally different design can render a lot of busy-work obsolete -- is one that resonates with me. But there are a lot of aspects of this that are all mashed together a bit in the article, so I want to break them apart and look at them one by one.

No comment yet.
Scoop.it!

Data binding with Object.observe

Data binding with Object.observe | JavaScript for Line of Business Applications | Scoop.it
Two-way data binding greatly simplifies writing views in web applications. The code in this article uses Object.observe to implement a simple two-way data binding in about 100 lines of code.
No comment yet.
Scoop.it!

D3 Tutorials

D3 Tutorials | JavaScript for Line of Business Applications | Scoop.it

These tutorials evolved out of my own process of learning how to use D3. You already know that D3 is an extraordinary tool for mapping data within web pages, written by Mike Bostock. Many people, including myself, come to D3 with backgrounds in design, mapping, and data visualization, but not programming and computer science.

Yet D3 employs advanced JavaScript techniques, so learning to use D3 often means learning a lot about JavaScript. For many datavis folks, D3 is their introduction to JavaScript. It’s hard enough to learn a new programming language, let alone a new tool built on that language. D3 is amazing and will enable you to do great things with JavaScript that you never would have even attempted. The time you spend learning both the language and the tool will provide an incredible payoff.

My goal is to reduce that learning time, so you can start creating awesome stuff sooner.


* Fundamentals
* Setup
* Adding elements
* Chaining methods
* Binding data
* Using your data
* Drawing divs
* The power of data()
* An SVG primer
* Drawing SVGs
* Types of data
* Making a bar chart
* Making a scatterplot
* Scales
* Axes

No comment yet.
Scoop.it!

D3 and React - the future of charting components?

D3 and React - the future of charting components? | JavaScript for Line of Business Applications | Scoop.it

Inspiration for combining React with D3 came from reading the following two blog posts where AngularJS was used as a part replacement for D3.

* Replacing (most of) d3.js with pure SVG + AngularJS
* Screw D3.js, Bar Charts in AngularJS


In these articles, AngularJS was used to manipulate the SVG elements, rather than D3.js. It had been relegated to providing the axis scales, calculating shape dimensions and path coordinates.

I was convinced that React could take Angular's place. Bringing with it the benefits of the web component style charting tags that the JSX syntax would allow me to create.

This would allow me to specify my chart component in the domain and terms of charting: Chart, Bar, Line and DataSeries. Rather than the actual implementation detail of SVG elements such as g, path, rect.

No comment yet.
Scoop.it!

A Client-Server Dart App From Scratch: Getting Started

A Client-Server Dart App From Scratch: Getting Started | JavaScript for Line of Business Applications | Scoop.it
An introduction to creating a client-server dart app: setting up the environment, making sure we have the latest SDK, and going over some Dart basics.
No comment yet.
Scoop.it!

TDD and BDD With The MEAN Stack: Introduction

As the MEAN stack is growing in adoption, a variety of testing strategies have sprouted up on the interwebs. As I have started to dig deeper into automated testing strategies for both sides of the MEAN stack, I have found it difficult to find advice or material on how to setup an environment to support the mockist style of test-driving the implementation. Many articles offer some light recommendations, but are typically more classicist-oriented. I’d like to help fill the gap by outlining a tooling strategy which I believe enables the following:

  • Automation
  • Mockist unit testing
  • BDD/ATDD testing
  • End-To-End system testing
Jan Hesse's insight:

set up: http://attackofzach.com/bdd-with-mean-the-server-part-1/

No comment yet.
Scoop.it!

A modern JavaScript router in 100 lines

Emberjs are truly build on top of a Router class. I'm still not sure that this is a concept which I like, but I'm absolutely sure that AbsurdJS should have a build-in Router. And, as with everything in this little library, it should be small, simple class. Let's see how such a module may look like.
No comment yet.
Scoop.it!

How to (semi-)automate JavaScript refactoring

How to (semi-)automate JavaScript refactoring | JavaScript for Line of Business Applications | Scoop.it

Computers aren’t ready to write much of our code for us, but they can still help us clean and improve our code.
Giles Bowkett demonstrates a wide variety of ways to write code that helps refactor code, showing developers a variety of ways to clean up and simplify their JavaScript. He gives ‘disposable robot assassin at large’ as his title, but it fit better with the code he is demonstrating.
Bowkett explores many options and iterations of his automation ideas...
It’s an amazing mix of capabilities that let you build your own robot (code) assassins.

No comment yet.