Posts

Showing posts with the label Dojo

Engage 2017 and Presentation - Unleash the Power of REST APIs with Dojo

At the beginning of this week, I was fortunate enough to attend Engage 2017. This was the first time that I had not only presented at Engage, but also attended Engage.  Theo does an amazing job in creating this premier event.  The turnout for my session, "Unleash the Power of REST APIs with Dojo"  was more than I expected. It has been awhile since I was in Europe.  So I took a couple days off before Engage to visit Amsterdam which I have never been to and a couple days after Engage to visit Belgium.  Amsterdam, though it has a lot of history, I found it too much of a tourist trap.  After the first day, I wandered off to the outskirt of the city where there were less tourist and had great time.  I got the Amsterdam Card and got into most of the museums and places at no additional cost.  I was able to ride the metro and trams with this card at no extra charge.  However, it does not work for some buses.  The lockers in Amsterdam station a...

Data Binding and React with Dojo

If you have developed with XPages, this might have been your first experience with the Dojo framework.  However, for many the experience have been frustrating and negative. Unfortunately, IBM's implementation of Dojo into XPages was limited and really restricted the potential of Dojo. It never implemented the newer AMD design approach nor the many of the capabilities of Dojo. Many developers who went towards the JavaScript Framework/REST approach with Domino implemented Angular, React, and even Vue for interfacing to the Domino server and bypassed frameworks like Dojo.  One of the big buzzwords for these newer frameworks is react and single/two-way data binding. As a designer and developer who uses Dojo to create UIs  that work with RESTful APIs /Domino, it is frustrating to see all this attention to Angular and React when all the cool things they are known for has been in Dojo for years and in many ways before these frameworks. Recently, I presented a session calle...

Creating Bootstrap Widgets Using Dojo at ATLUG

Thanks to Lisa and Darren Duke, I will be presenting at ATLUG on May 19, 2016 on combining my two favorite open source frameworks, Twitter Bootstrap and Dojo, to create widgets that your can use in your web-based application. This presentation is not XPages specific. The presentation will be held at the IBM Technical Exploration Center in Atlanta. So if you are a web developer using or thinking about using Dojo and Bootstrap come join me or to just listen to me rant and rave. IBM Corp  (Building A) 6303  Barfield Rd.,  NE Atlanta ,  GA   30328 Technical   Exploration   Center Creating Bootstrap Widgets Using Dojo Twitter Bootstrap is one of the most popular responsive CSS frameworks available. Dojo is one of the most comprehensive and powerful JavaScript framework available. However, Bootstrap only comes with jQuery-based widgets by default. But if you can only combine Bootstrap and Dojo together, you as designers and develo pers w...

More Fun Creating Dojo widgets and MVC

Here is another article in my "Fun with Dojo" series. Dojo traditionally has been considered slow.  One reason is that Dojo loads alot of modules before it instantiates the page.  Dojo with AMD helps reduce the number of modules when it first loads but not the number of modules.  This is great.  However, one thing that I really dislike are Dojo Dijit widgets.  They are heavy, slow, and require a lot of modules to be loaded. We like the Bootstrap widgets because they are lightweight. So instead of using Dijits that are built into XPages we created our own lightweight Dojo Bootstrap widgets that utilized the most minimal amount of required Dijit modules and dependencies. One of the things that we had to figured out was what bare bone modules that we needed beside dijit._Widget in order to create our own widgets and include them in the loading process.  When we were using Dojo 1.53, we created a custom loader with all the re...

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...

Why an Ideal MVC Framework Fails

One of the "Next Big Things" these days is the use an MVC framework for developing Web applications. There are a number of MVC frameworks out there including Backbone, Ember, and the rapidly growing Angular.  Ideally these MVC frameworks are great, hook things together and any changes to the model (data) and all the views are updated based on the controller code. If there is changes to the model, the data is automatically updated on the server. This is the ideal case. However, it assumes one critical thing, you have the access rights to CRUD data on the server. This is an extremely dangerous assumption. In our iPhora security model, we assume the opposite and you do not have access rights to any data on the server. We do not trust anything and any request. We assume that you are trying to hack and inject. Your authorization is checked during each request. We looked at using Angular since it is the hot ...

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...

Transforming Domino into a Social Collaboration Platform, Part 2B - Experimentation

Transforming Domino into a Social Collaboration Platform, Part 1 - Where Do We Begin? Transforming Domino into a Social Collaboration Platform, Part 2A - Experimentation This is the second part of our experimentation portion of the series. In Part 2A, I talked about the different experiments that we did for creating web pages for our social collaboration applications and the design of the back-end database.  In part 2B, I will be talking about the application structure and business process and workflow management that you need in order to have a successful social collaboration tool.  As I mentioned before, there were four areas of technical challenges that we had to overcome. Web Interface Generation Database Infrastructure Application Structure Business Process and Workflow Management In this blog we will cover the last two. Application Structure Traditionally with Domino applications, an application consist of one or mo...

Transforming Domino into a Social Collaboration Platform Part 2A - Experimentation

http://dominointerface.blogspot.com/2014/05/transforming-domino-into-social.html In my last blog, I described our desire to a create a community-based social collaboration platform designed to meet the needs of small and medium-sized organization.  This post is the geeky part of this series. Only being naïve would one have taken on this journey. So the great experimentation began. So we wanted to transform Domino into a social collaboration platform.  But what did that mean in the technical sense. Since data is fluid and mostly unstructured, we needed the entire infrastructure to be fluid and that was the challenge.  The challenges create many forks in the road of which many were dead ends. There was four areas of technical challenges that we had to overcome. Web Interface Generation Database Infrastructure Application Structure Business Process and Workflow Management Web Page and Interface Though XPages technically separates...

Don't Get Disconnected with Connect

Image
Here is another of my "My Experience in Building Dojo Widgets" post. Dojo.connect (dojo/on) is a versatile and important part of dojo that handle events.  Along with dojo.subscribe and dojo.publish these three features of Dojo provide a powerful set of tools to query the DOM. <div class="widget" id="happy"> <ul> <li id="1"> <a href="#" tabindex="-1"><i class="icon-tools"></i>Hello</a> </li> <li id="2"> <a href="#" tabindex="-1"><i class="icon-tools"></i>Hello</a> </li> <li id="3"> <a href="#" tabindex="-1"><i class="icon-tools"></i>Hello</a> </li> <li id="4"> <a href="#" tabindex="-1"><i class="icon-tools"></i>Hello</a> </li> ...

When This is This and What is This, but What is not This, Dojo Event and Objects

In the past couple of years, I have been building Dojo Bootstrap widgets from stratch rather than using standard Dojo widgets and styling using a Bootstrap theme.  Why in the world would you do that might you ask.  Sometimes I also ask myself that question. There are many advantages, including adding security features that are not founded normally. Since we RESTFul JSON services, the widgets are optimized for our format.  In addition, the widgets are automatically binded with the RESTFul JSON services when the web page is instantiated.  So as part of my Dojo adventures, I had to learn and relearn Dojo again and again. There is so many different ways to do things, but the right way is sometimes elusive.  One advantage of Dojo over JQuery is that Dojo forces you to use a pattern for creating widgets which I really like.  It is hard enough for me to follow what I did 2 months ago.  Imagine if another developer had to follow my code years later. One pr...

Creating Twitter Bootstrap Widgets - Part IIIA - Using Dojo To Bring It Together

Creating Twitter Bootstrap Widgets - Part I - Anatomy of a Widget Creating Twitter Bootstrap Widgets - Part II - Let's Assemble Creating Twitter Bootstrap Widgets - Part IIIA - Using Dojo To Bring It Together Note:  With a customer deadline coming up and with all the work that MWLUG 2013 requires, I haven't had the time to devote to writing this series.  So I took most of today to complete this part. As I was writing this part of the series, I realized that I should talk about creating widgets using Dojo in general. So I split this part into part A and B because it was getting way too long. Welcome to part three of my five part series "Creating Twitter Bootstrap Widgets". In the first two parts, we talked about how Bootstrap widgets can be assembled using a consistent framework of standard HTML elements with CSS3 styling.  In part three, we will connect together our combo box widget using Dojo and make it functional.   As XPages developer you should be famil...

Creating Twitter Bootstrap Widgets - Part II - Let's Assemble

Image
Creating Twitter Bootstrap Widgets - Part I - Anatomy of a Widget Creating Twitter Bootstrap Widgets - Part II - Let's Assemble Creating Twitter Bootstrap Widgets - Part IIIA - Using Dojo To Bring It Together This is two part of my five part series "Creating Twitter Bootstrap Widgets".   As I mentioned in part one of this series, Twitter Bootstrap widgets are built from a collection standard HTML elements, styled, and programmed to function as a single unit. The goal of this series is to teach you how to create a Bootstrap widget that utilizes the Bootstrap CSS and Dojo. The use of Dojo with Bootstrap is very limited with the exception of Kevin Armstrong who did an incredible job with his Dojo Bootstrap, http://dojobootstrap.com. Our example is a combo box that we are building to replace the standard Bootstrap combo box. In part one, we built a widget that looks like a combo box but did not have a drop down menu associated with it to allow the user to make a select...