< Previous Article Next Article >

Hello Single Page Apps!

If you're building a web site with content, having multiple pages makes sense.

But if you're building business applications, you should consider using Single Page Apps. It simply means your browser page never reloads.

Single Page Apps can both simplify development and improve performance.

NodeRun has built-in capabilities to make Single Page App programming very easy. Here are 3 capabilities you will want to learn about:

  • Rich Displays - you can use Rich Displays to build interfaces very quickly without having to write a lot of markup.

  • Stateful Apps - you can use NodeRun's stateful app support to easily connect your data and business logic to your displays.

  • React.js / Vue.js - you can use front-end frameworks like React or Vue to organize your application into smaller components that work together.

Choosing between Stateful and React/Vue

The choice between a Stateful server-side app and an app built with a client-side framework like React or Vue is mutually exclusive. You will have to decide what is most appropriate for your needs.

If your app uses a database and involves a certain amount of backend business logic, a Stateful app can provide many benefits over client-side driven apps.

However, keep in mind that a Stateful app is more opinionated. It guides you through what it feels are best practices vs. letting you build your own application architecture from scratch using raw JavaScript and markup code.

A Stateful app provides several advantages

  • Session handling is built-in
  • It is specifically geared towards business applications
  • There is less code and it is easier to get started with
  • Communication between client and server is automatically facilitated
  • Components can connect directly to a database without you having to write any code
  • It’s great for backend developers who want to implement full-stack apps
  • Interfaces are easier to build, especially if you aren’t an expert with raw markup and CSS

React, Vue, or another client-side framework can also be a great choice

  • These frameworks are multi-purpose and popular
  • They are great if you already have existing React or Vue code, know these frameworks well, or rely on front-end developers that are familiar with one of these frameworks
  • They work well if you prefer to write your own custom session handling
  • These frameworks are good if you favor writing all markup from scratch (JSX / HTML) and having a greater degree of control vs using prebuilt DHTML widgets
  • These frameworks can be ideal if your app is mostly front-end and does not use a database or there is not much backend business logic involved
  • Vue or React work well if you prefer the ability to easily mix markup and Rich Display widgets

Questions?

Have questions about this topic? Ask for help on our NodeRun Discussion Forum.

< Previous Article Next Article >