JavaScript for Line of Business Applications
596.1K views | +0 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

Current selected tag: 'React'. Clear
Scoop.it!

React.js in pure JavaScript - Deep explanation for newbies

React.js in pure JavaScript - Deep explanation for newbies | JavaScript for Line of Business Applications | Scoop.it

As you might now react.js is a framework to create user interfaces in a web context. What is special about this? Is amazingly fast! (and supports server-side rendering) But has a downside, which requires you to change the way you think about web interfaces (see above).

There are a lot of tutorials about react.js but almost none, or very hard to find, in pure JavaScript. They all use the react.js special syntax. But I don't want to have another javascript pre-processor between each code change so this is the main reason.

The most complicated part of understanding react.js was how exatly the arguments passed in the components, and which ones can change and which can't...

No comment yet.
Scoop.it!

Play Framework and Facebook's React library

Play Framework and Facebook's React library | JavaScript for Line of Business Applications | Scoop.it

Over the holidays I have discovered Facebook’s React, an interesting library for generating reactive user interfaces. I wanted to try it out in a real-world application, which reminded of one I still had running as a demo: sse-chat, a little chat application I wrote last summer for learning how to make Play Framework and AngularJS cooperate in a very basic way. So I thought, why not rewrite the client side using React, offering the exact same functionality as the AngularJS version. Both are available at the same time in the new version, with no changes to the backend code, except for the added route as both versions can be accessed in parallel.

The contraint of making it behave exactly like the AngularJS version was a great exercise and it really only took an afternoon to complete. Touching the existing demo version also had me notice that the live version of it had been up for like 4 months or so, without any trouble. I have the same experience with my BirdWatch application. Kudos to the Play Framework developers for that, and same for Akka, which provides the supervised Actor architecture presumably enabling such reliable server systems.

No comment yet.
Scoop.it!

React vs Angular

React vs Angular | JavaScript for Line of Business Applications | Scoop.it

First of all I think it’s important to evaluate technologies on objective rather than subjective features. “It feels nicer” or “it’s cleaner” aren’t valid reasons: performance, modularity, community size and ease of testing / integration with other tools are.

I’ve done a lot of work benchmarking, building apps, and reading the code of Angular to try to come up with a reasonable comparison between their ways of doing things.

 

* Community / project maturity
* Performance
* Mechanisms for code reuse
* Server rendering
* Tooling integration
* Simplicity
* My conclusion

No comment yet.
Scoop.it!

A slice of React, Clojurescript and Om

A slice of React, Clojurescript and Om | JavaScript for Line of Business Applications | Scoop.it

React has sparked a lot of interest in the Clojure community lately (and perhaps, hopefully the other way around as well), and for good reasons. At the very core, React lets you build up your DOM representation in a functional fashion by composing pure functions and you have a simple building block for everything: React components.

The core idea in Om is to simplify idiomatic state management with Clojurescript’s immutable datastructures, while still getting all the performance (and more), as well as adding some syntactic sugar.

I going to take a piece of the React tutorial and present in first Javascript, then Clojurescript and lastly using Om. Hopefully this will let us discover how plain Clojurescript interacts with React and inform us on some of the design decisions in Om.

No comment yet.
Scoop.it!

NgReact.js - React Components in Angular

Facebook's React library is designed to be used as a view component atop other JavaScript frameworks. NgReact is a pair of proof of concept directives that show how React can cooperate with Angular, resulting in performance gains nearly up to 70% (or, well, losses up to 450%).

No comment yet.
Scoop.it!

Server-side React with PHP

Server-side React with PHP | JavaScript for Line of Business Applications | Scoop.it

So you know about React and how to build your own components. And you know you can run JavaScript inside PHP scripts, thanks to v8js. So nothing can stop you from rendering React components on the server side in PHP. Which means you send the first view from the server and then continue from there.


Part 1 ended with todos. The first one was to couple the server-side generated code with the client-side React, so that any updates past the initial page load will be handled by React's client JS, which is where React shines. Let's see how you can do just that.

Jan Hesse's insight:

Part 2: http://www.phpied.com/server-side-react-with-php-part-2/

No comment yet.
Scoop.it!

React: Rethinking Best Practices

React is a different way to write JavaScript apps. When it was introduced at JSConf US in May, the audience was shocked by some of its design principles.

We’re trying to push the limits of what’s possible on the web with React. My talk will start with a brief introduction to the framework, and then dive into three controversial topics: Throwing out the notion of templates and building views with JavaScript, “re-rendering” your entire application when your data changes, and a lightweight implementation of the DOM and events.

No comment yet.
Scoop.it!

React Page - server- and client-side rendering for faster pages

React Page - server- and client-side rendering for faster pages | JavaScript for Line of Business Applications | Scoop.it

Jordan Walke implemented a complete React project creator called react-page. It supports both server-side and client-side rendering, source transform and packaging JSX files using CommonJS modules, and instant reload.

Why Server Rendering?
* Faster Pages: Markup displayed before downloading JS (with SEO benefits)
* Page generation on a fast server vs. low power client devices.
* Instantly refresh while developing.
* Static content sites: As easy as a single wget command.

Why React?
* React is a client/server rendering framework from the ground up.
* When performance constraints change, simply change where you render it - don't change your app.
* React is functional. Explore the documentation on the React Github Page.
* Server rendering optional - you can always just use React as a declarative client side framework.

No comment yet.
Scoop.it!

AngularJS and SEO - Part 2 - Title and meta description

Getting your site in the Google and Bing index may be the most important step but you still need to optimize your content for searchability.

e.g. you will have to deal with title tags and meta description for each page in order to rank well.
There is nothing built in for AngularJS to deal with this, so we had to roll our own directives for this.

No comment yet.
Scoop.it!

Moving From Backbone To React

Moving From Backbone To React | JavaScript for Line of Business Applications | Scoop.it
We've been building a fairly big, interaction-heavy JavaScript app for Propeller. We started with Backbone as the base for most of our code, but we started to feel some pain at the view layer as our app grew larger.

Then, just as we started to looking for new solutions, React appeared.

What is React? In effect, React is a replacement for Backbone.View. It's not a huge application-level framework like Angular or Ember, and it can peacefully coexist with existing components likeBackbone.Model.

Why did we replace Backbone.View? The biggest headache with vanilla Backbone is once you start nesting Backbone.View objects, you're basically on your own with regards to managing the lifecycle of the view hierarchy.

No comment yet.
Scoop.it!

Scala.js and ReactJS - Why would someone want Scala on the client?

Scala.js and ReactJS - Why would someone want Scala on the client? | JavaScript for Line of Business Applications | Scoop.it

In this article I will present a simple reactive web application using Scala.js and ReactJS on the client side. It is based on sse-chat, an application I initially wrote for demonstrating the usage of AngularJS with Play Framework. I then rewrote the client for an article about using ReactJS on the client side. In the latest version now, there is an additional client that connects to the same server and utilizes Scala.js for building the web client. I recently gave a talk about this at Ping Conference in Budapest, check it out if you’re interested. I discovered ReactJS through David Nolen’s blog and his excellent OM library, which combines ReactJS with ClojureScript. His second article on Om also inspired me to try out an undo functionality with the immutable data structures that Scala.js has to offer. 

No comment yet.
Scoop.it!

Writing React components as CommonJS modules

Writing React components as CommonJS modules | JavaScript for Line of Business Applications | Scoop.it

One of the libraries gaining interest at the moment is Facebook's React JS library. It mainly concerns itself with "the V in MVC" and encourages developers to break their app into resuable, modular components. The Virtual DOM is a great feature on its own, and I encourage you to investigate React if you haven't yet.

In this post I'll be explaining how your React components can be used as CommonJS modules and then made browser friendly via Grunt. Using React this way (as opposed to Bower, or just downloading the files manually) allows easy re-use of components on the server as well as all the benefits of modularising your code.

No comment yet.
Scoop.it!

React beginner tutorial: implementing the board game Go

React is “a javascript library for building user interfaces”. If you haven’t done so already, I highly recommend you watch Pete Hunt’s presentationon React’s design principles. React is a relatively simple library, especially when compared to full-fledged MVC frameworks like Angular, Ember, Backbone, and the rest. It’s a pleasure to work with, so let’s get started.

Today, we’ll be implementing the board game Go. If you don’t know how to play, that’s okay. All you need to know for now is that players alternate placing stones on intersections of the board’s grid to capture their opponent’s stones and claim the greatest amount of territory. Take a look at the live preview to get an idea of what we’ll be building.

No comment yet.
Scoop.it!

Frontend components in React

Frontend components in React | JavaScript for Line of Business Applications | Scoop.it

Last week I made a presentation for meet.js PL about React. meet.js is a free front-end meetup organized by web enthusiasts in 6 major Polish cities - Warsaw, Gdańsk, Poznań, Wrocław, Cracow and Katowice.

In a nutshell, I presented why we chose React among other available options (ember.js, angular, backbone ...) in AgFlow, where I’m leading an application development.

Also I try to highlight some problems with MVC pattern everywhere.

I really like a way of React frontend components development. It makes more clear for us to implement use cases views.

Enjoy! 

No comment yet.
Scoop.it!

The Future of JavaScript MVC Frameworks

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

We've known this for some time over here in the ClojureScript corner of the world - all of our collections are immutable and modeled directly on the original Clojure versions written in Java. Modern JavaScript engines have now been tuned to the point that it's no longer uncommon to see collection performance within 2.5X of the Java Virtual Machine.

Wait, wait, wait. What does the performance of persistent data structures have to do with the future of JavaScript MVCs?

A whole lot.

No comment yet.
Scoop.it!

Intro to the React Framework

Intro to the React Framework | JavaScript for Line of Business Applications | Scoop.it

In today’s world of Javascript Application frameworks, design philosophy is the key differentiating factor. If you compare the popular JS frameworks, such as EmberJS, AngularJS, Backbone, Knockout, etc. you are sure to find differences in their abstractions, thinking models, and of course the terminology. This is a direct consequence of the underlying design philosophy. But, in principle, they all do one thing, which is to abstract out the DOM in such a way that you don’t deal directly with HTML Elements.

I personally think that a framework becomes interesting when it provides a set of abstractions that enable a different mode of thinking. In this aspect, react, the new JS framework from the folks at Facebook, will force you to rethink (to some extent) how you decompose the UI and interactions of your application. Having reached version 0.4.1 (as of this writing), React provides a surprisingly simple, yet effective model for building JS apps that mixes a delightful cocktail of a different kind.

In this article, we’ll explore the building blocks of React and embrace a style of thinking that may seem counter-intuitive on the first go. But, as the React docs say: “Give it Five Minutes” and then you will see how this approach will become more natural.

No comment yet.
Scoop.it!

Reactive table

Reactive table | JavaScript for Line of Business Applications | Scoop.it

React is all about components. So let's build one.

You see that React components are defined using a regular JS object. Some properties and methods of the object such as render() have special meanings, the rest is upforgrabs.

A table is a way to neatly and orderly present some data. The data is front and center, the most important thing. And data is what you should focus on - retrieving, updating, saving, etc.

Once you have the data, you let React take care of the presentation part.

You want the UI to react to changes in the data. So you need a stateful component. Meaning one that has state. This is easier than it sounds.

As you can see the state is an object. Simple as that, the old familiar {key: value}situation. In this case the state is just one property of the state object, appropriately named data. ...


No comment yet.
Scoop.it!

Facebook React & Meteor (think pure event driven ui)

Facebook React & Meteor (think pure event driven ui) | JavaScript for Line of Business Applications | Scoop.it

Ben Newman made a 13-lines wrapper to use React and Meteor together. Meteor handles the real-time data synchronization between client and server. React provides the declarative way to write the interface and only updates the parts of the UI that changed.

This repository defines a Meteor package that automatically integrates the React rendering framework on both the client and the server, to complement or replace the default Handlebars templating system.

The React core is officially agnostic about how you fetch and update your data, so it is far from obvious which approach is the best. This package provides one answer to that question (use Meteor!), and I hope you will find it a compelling combination.

No comment yet.
Scoop.it!

AngularJS and SEO - Part 1 - Get your JS site indexed

In this series we will go through a few steps on how to make your AngularJS site crawlable by google and other search engines.
Note: This part does apply to Knockout, Backbone and other frameworks to.

For this series we can safely say that googlebot and bingbot does NOT execute AngularJS and you will have to deal with this manually.

The fact that there is push state and javascript involved on the client side is completely beside the point, server side content and URL’s that resolve is what matters.

No comment yet.