Posts

Showing posts with the label JavaScript

Integration of Microsoft VS Code with Domino, a Hack

Image
Many components make up a Web application some of which includes CSS and JavaScript. Both CSS and JavaScript has rapidly evolved over the many years that Domino has been used as a Web Application Server.  Unfortunately, the editors in Domino Designer has not evolved and you can not add and edit JavaScript ES6 code for example. The new Domino 14.5 I have been told allows one to edit ES6 JavaScript as a file resource, but not as a JavaScript script library file. One of the most popular tools for editing CSS and JavaScript is Microsoft VS Code. There are some many extensions that you can download and work with many different programming languages.  One very nice thing about Microsoft VS Code is that it is free and most developers are familiar with VS Code. In addition, it is much nicer of an editor than what is available in the Domino Designer.  There was discussions about VS Code integration with Domino at one of the past CollabSphere a few years ago.  Unfortunately, t...

Our Journey in Optimizing and Bundling JavaScript for Web Applications

Image
When building a web application, optimizing the loading process is important. Previously, we used Uglify-ES and recently Terser to minify individual JavaScript files to help reduce the packages and load time. With the next release of iPhora Automatic coming very soon, we wanted to significantly reduce the loading time needed and the number of HTTP requests handled by the Domino server. Our struggles for the past few weeks have been figuring out the right JavaScript bundler that works with our Dojo Toolkit-based framework. So why are we still using Dojo Toolkit you might first ask? Many have moved away from Dojo Toolkit, the granddaddy of JavaScript frameworks. Dojo provides us the core widget inheritance framework that is not just used for creating widgets like fields and combo boxes, but is used for building the many different app layers of iPhora not just statically but dynamically in real-time. It allows us to have a secure and fast SPA (single page application) architecture. We d...

Node.js Comes to MWLUG/CollabSphere 2018

Image
As I said in my previous blog, Node.js with Domino v10 brings significant opportunities to the ICS community whether you are an IBMers, IBM Customer, IBM Business Partner, ISV, developer or administrators. I have talked to a number of individuals and they feel there is a lot of potential for them.  IBM will be releasing two different betas.  The second beta will include the Node.js integration with Domino.  I wished it was included in the first beta. I would have love to test the Node integration earlier.  We have been waiting for the Node integration to extend the power of our iPhora platform. In preparation for the up and coming Node/Domino launch, we are providing an entire series of Node/Domino sessions and discussions at MWLUG/CollabSphere 2018 starting from the basics to the more advanced use of Node in Node-Red along with JavaScript sessions which will be critical for the development of applications with Node.js. We hope to see everyone there at CollabSp...

Announcing the CollabSphere 2018 Sessions

I am please to announce the CollabSphere 2018 sessions are now available on the CollaSphere web site at http://collabsphere.org/ug/collabsphere2018.nsf/sessions.html.   We have great speakers coming from all over the world including close to two dozen IBM Champions. With the renew focus on the Domino 10 family of products plus IBM Watson Workspace and IBM Connections, CollabSphere 2018 will be celebrating our tenth anniversary with one of the best lineup of sessions we have ever had. 53 Business and Technical Sessions 8 Roundtables 6 Chat Sessions 3 Workshops Opening General Session Opening General Session - Domino Closing General Session

When your Tool is a Hammer, Everything is a Nail, Transformation of Domino - Part 2

The recent announcement by IBM to continue the development and support for the IBM Domino platform indefinitely was great timing for part 2 of this series. This series is about the direction that we are taking Domino. This journey has taken more than five years with many different designs and experiments to get to where we are in our iPhora technology. You can find Part 1 of this series  here .  There are many tools and solutions out there from many vendors for "Modernizing" a Notes application. But what does that really mean?  In most cases, that means replacing the Notes application interface with a Web interface and making a better UI experience for the user. But for us application modernization is not just about the front-end but also but how the data is collected, managed, stored and processed. How it integrates with outside third-party services. Most Domino application modernization leaves the data untouched in the same structure. XPages mimics the Notes applica...

Our Adventures into Creating a Secure MVC Framework - Part 3 - Experimentation

Image
Now that we have defined our design requirements, we needed to determine the tools and approach that we would use to create our framework. We had created previous versions of iPhora Touch using Dojo and wanted to start from scratch on what tools we would use to create our framework. Everyone that I talked to asked me why I was using Dojo since it is big and slow.  So we started looking at different options.  Do we take one of the existing more bare bones MVC framework like Backbone and take components from them to create our framework or do we start totally from scratch using JavaScript or jQuery. There are so many frameworks out there it is amazing. You can find many examples of MVC frameworks in action at todomvc.com. It was very difficult reading up on each framework, understanding them, and experimenting with them to see if they would work for us. Since we were already familiar with Dojo, we decide to start from there.  We found a couple of articles and frameworks...

Our Adventures into Creating a Secure MVC Framework - Part 2 - Design Requirements

Image
When we created iPhora Touch version 2, it was a multiple page application that utilized Dojo 1.53 and Bootstrap 2.32.  The interface worked well on desktops but broke down when used on tablets. It was totally unusable in a phone environment.  Since it was a multiple page solution each page needed to reload Dojo as you jump from page to page. Since we wanted a secured environment, pages could not be cached. However, this slowed down the loading and response of each page.  Since we were using Dojo 1.53 at the time we did not benefit from any form of AMD. iPhora Touch V2 Community Home Page We wanted to redesign the interface to work well with mobile devices and desktops, have better performance, but at the same time to be a secured environment. Though our iPhora Touch solution is a social community-based solution, we designed it to be a closed environment by default and it is assumed that you are not allowed access to anything, which is contrary to how most soci...

Our Adventures into Creating a Secure MVC Framework - Part 1 - Introduction

Image
As I was writing this series, it cause me to rethink some approaches and redesign part of our MVC framework. Therefore, it took me a bit longer to start this series than I thought. But here goes. Introduction The concept of Model-View-Controller MVC can be implemented in two ways, using a server-side component framework that generates the Web application interface/view or as a JavaScript framework that gets data from the server and generates the Web application interface/view . In this series, we will be discussing how we created and implemented a JavaScript MVC framework. If you a Java developer and would like to implement a server-side MVC framework, Vaadin is a good server-side MVC framework to look into.  For developers in the XPages community, Ulrich Krause and Paul Withers has been blogging about Vaadin. Each approach has its advantages and which approach you use is based on your development skills, tools, and architecture of your web application. If you are a XPages ...

The Good, Bad, and Ugly about AMD in Dojo

Image
We were testing iPhora Touch 2 with the attendees of MWLUG 2014 in the MWLUG portal and as usual, the interface had issues even after having outside users provide feedback before we rolled it out.  When you are so focused on the creation process it hard to see issues until it is seen by fresh pair of eyes.  So we are working on a new faster and improved interface for iPhora Touch. This is the evolution of any product. Since we are using a JavaScript/JSON Restful API approach most of the changes will be on the front end and only minor changes to the back end which is great.  In theory we can swap out different interfaces with little impact on the back end.  This is where the newer AMD approach for Dojo comes into play. The use of AMD in Dojo allows us to modularize the UI components even more than what we had.  Therefore, we have been upgrading all the iPhora widgets from Dojo 1.53 to Dojo 1.10.0 and at the same time upgrading from Bootstrap 2.32 to 3.2 an...

Don't What it, Hitch It

Async callbacks and closures is an incredible thing about JavaScript.   This is what makes environments like nodejs possible, a topic of many blogs to come.  Many of the JavaScript frameworks like my favorite framework Dojo have the ability to deal with closures and callbacks.  One of the issues that one needs to deal with is getting a handle to the current scope within a closure. We discussed this and how to deal with it in Dojo in a previous blog. http://dominointerface.blogspot.com/2014/03/when-is-this-is-this-and-what-is-this.html The nice thing about Dojo is how extensive the library is.  This is also a negative thing since there is so many features that you might not beware of. As I am converting our iPhora library from Dojo 1.53 to Dojo 1.10.0, I realized there is also another method that you can use to get a handle to the current scope within a closure and that is dojo.hitch which has been around for a long time.  In our prev...

Gotcha, Creating Dynamic Script Blocks Using SSJS

For our iPhora applications we only use one XPage and dynamically create the content that appears.  We do this by storing the dynamic content in Notes Rich Text fields and using SSJS to read and generate the HTML/JavaScript during runtime.  Since we are moving to an single page MVC model, we were adding a few addition xp:scriptBlock to generate the initial loader and pulling the information from a NotesRichText field.  We were using doc.getFirstValueString('richtextfield') to pull and create the script. No problem until, we had a JavaScript object declaration that was longer than 72 odd characters. Unfortunately, there is an issue with Notes Rich Text fields that we encountered in the past using LotusScript that I forgot all about.  When you read a Notes Rich Text field it will automatically add a carriage return after 72 characters and this can drive you crazy. If the carriage return occurs between a JavaScript object declaration then yo...