Blog

Apr 24

Intro to Intern webcast

By on April 24, 2014 5:00 am

Last month, we conducted a live webcast to provide an Introduction to Intern, SitePen’s open source testing framework.

Our webcast covered:

  • An overview of Intern’s numerous functional and unit testing features and capabilities
  • Mocking objects and data
  • Injecting dependencies
  • Troubleshooting
  • Future direction of Intern

While it’s too late to attend this webcast and heckle us with live questions, we recorded the session and have made it available for you online:

We encourage you to use Intern in your current application and then tell us about your experience. You can find us on Stack Overflow where we’re answering questions and, of course, we cover Intern as part of our JavaScript support and as a topic in our Dojo workshops. If you’d like more information about having SitePen assist your organization with implementing and refining your process for JavaScript testing, please let us know.

Jan 29

Dojo FAQ: Why is dojo.* unavailable when I set async: true in data-dojo-config?

By on January 29, 2014 10:35 am

DojoFAQ
The evolution of the Dojo Toolkit from namespaces to AMD packages has resulted in many changes over the years. In Dojo 1.x, we strive to maintain forwards-compatibility, while introducing new features and best practices in parallel. Mixing modern best practices and legacy code can lead to unexpected behavior.

One issue we see fairly often is setting async: true in the data-dojo-config property of Dojo’s script tag. This configuration setting tells Dojo to load resources as AMD modules using its asynchronous module loader. Many users choose this, but then rely on legacy package names such as dojo and dijit when migrating their old code. Unfortunately, this leads to failures when you try to use dojo.* statements within your application. This is a simple issue to identify and correct.

Apr 3

Introducing dojo-amd-converter

By on April 3, 2013 9:30 am

AMD offers many benefits over the legacy Dojo module syntax. While Dojo is forwards-compatible, to take advantage of the benefits of AMD, developers are often faced with the challenge of migrating and refactoring large quantities of boilerplate code from the legacy dojo.provide/dojo.require syntax to AMD’s define and require. As we make the upgrade to AMD in our projects, we also usually want to leverage the latest version of our evolving APIs. With early work beginning on Dojo 2.0, we definitely need to work together as a community to automate as much of the upgrade process as possible.

Introducing the dojo-amd-converter

We have created an alpha quality release of dojo-amd-converter, a tool for helping you make a one-time migration of your existing source code to a newer version of Dojo.

Be warned, the tool handles only 70-80% of the manual conversion process, and generally does better with more standard usage of Dojo. Normally we wait a bit longer before announcing our projects, but this should be useful in its early alpha state. We know this tool has quite a few open issues that need to be fixed and we invite you to help us improve it.

Our hope is that this conversion tool, which is today useful for converting pre-AMD code to AMD code, could also form the basis for a community effort to make it possible to migrate code bases more efficiently from Dojo 1.x (pre-AMD or AMD) to Dojo 2.x. That work has not yet started, since Dojo 2.0 is not yet an actual thing.

Jan 25

Dojo Tutorial: Feature Detection and Device Optimized Builds

By on January 25, 2013 3:50 pm

As part of our great updates to the Dojo Tutorials for Dojo 1.8, we’ve been busy creating several new tutorials.

Feature Detection and Device Optimized Builds

preview Dojo 1.7+ now uses the popular has() pattern for feature detection in combination with a has()-aware build system. While it is easy enough to write feature detection tests with ad-hoc JavaScript expressions, the has() pattern defines a specific syntax such that the build system can detect these feature-based branches, and one can create application builds that are highly optimized for specific devices, with known feature shims factored out.

Check out the Feature Detection and Device Optimized Builds tutorial for Dojo 1.8 and 1.7!

Want to see a specific Tutorial? Want to Learn More?

Is there something you’d like to learn how to do with Dojo? Always wanted to know how something in Dojo works? Leave us a message in the blog comments and we’ll see about getting a tutorial created for you. Or sign-up for an upcoming SitePen Dojo Workshop to get a fully immersive hands-on experience with Dojo.

Nov 15

Dojo Tutorial: Key Events

By on November 15, 2012 4:36 pm

As part of our great updates to the Dojo Tutorials for Dojo 1.8, we’ve been busy creating several new tutorials.

Key Events

Key Events This tutorial teaches you how to easily handle keyboard events with Dojo’s event normalization and dojo/keys implementation.

Check out the Key Events tutorial for Dojo 1.8, 1.7, or 1.6!

Want to see a specific Tutorial? Want to Learn More?

Is there something you’d like to learn how to do with Dojo? Always wanted to know how something in Dojo works? Leave us a message in the blog comments and we’ll see about getting a tutorial created for you. Or sign-up for an upcoming SitePen Dojo Workshop to get a fully immersive hands-on experience with Dojo.

Nov 8

Dojo Tutorial: Augmenting Objects

By on November 8, 2012 9:59 am

As part of our great updates to the Dojo Tutorials for Dojo 1.8, we’ve been busy creating several new tutorials.

Augmenting Objects

Augmenting Objects In JavaScript applications, you’re working with objects all day long. This tutorial covers the features found in dojo/_base/lang for augmenting your objects efficiently.

Without further ado, check out the Augmenting Objects tutorial for Dojo 1.8, 1.7, or 1.6!

Want to see a specific Tutorial? Want to Learn More?

Is there something you’d like to learn how to do with Dojo? Always wanted to know how something in Dojo works? Leave us a message in the blog comments and we’ll see about getting a tutorial created for you. Or sign-up for an upcoming SitePen Dojo Workshop to get a fully immersive hands-on experience with Dojo.

Nov 7

Dojo Tutorial: Dojo Start

By on November 7, 2012 2:45 pm

As part of our great updates to the Dojo Tutorials for Dojo 1.8, we’ve been busy creating several new tutorials.

Dojo Start

Dojo Start How do I start learning Dojo? Where are the docs? How do I get support and training? Which Dojo version should I use? Why do I need to use a web server? How can I avoid common mistakes? How do I report issues? How do I contribute and get involved? These questions and more are answered with this introductory start tutorial.

Without further ado, check out the Dojo Start tutorial!

Want to see a specific Tutorial? Want to Learn More?

Is there something you’d like to learn how to do with Dojo? Always wanted to know how something in Dojo works? Leave us a message in the blog comments and we’ll see about getting a tutorial created for you. Or sign-up for an upcoming SitePen Dojo Workshop to get a fully immersive hands-on experience with Dojo.

Nov 6

Dojo Tutorial: D.O.H. Test Suite

By on November 6, 2012 2:41 pm

As part of our great updates to the Dojo Tutorials for Dojo 1.8, we’ve been busy creating several new tutorials.

D.O.H. Test Suite

D.O.H. Test Suite This tutorial teaches you how to set up a suite of unit tests with the D.O.H. unit test harness, and run them.

Check out the D.O.H. Test Suite tutorial for Dojo 1.8, 1.7, or 1.6!

Want to see a specific Tutorial? Want to Learn More?

Is there something you’d like to learn how to do with Dojo? Always wanted to know how something in Dojo works? Leave us a message in the blog comments and we’ll see about getting a tutorial created for you. Or sign-up for an upcoming SitePen Dojo Workshop to get a fully immersive hands-on experience with Dojo.

Nov 2

Dojo Tutorial: Loading Overlay

By on November 2, 2012 10:30 am

As part of our great updates to the Dojo Tutorials for Dojo 1.8, we’ve been busy creating several new tutorials.

Loading Overlay

Loading Overlay This tutorial teaches you how to create an overlay that puts you in control of the user experience while the loading of dependencies and rendering of the UI takes place in the background.

Check out the Loading Overlay tutorial for Dojo 1.8, 1.7, or 1.6!

Want to see a specific Tutorial? Want to Learn More?

Is there something you’d like to learn how to do with Dojo? Always wanted to know how something in Dojo works? Leave us a message in the blog comments and we’ll see about getting a tutorial created for you. Or sign-up for an upcoming SitePen Dojo Workshop to get a fully immersive hands-on experience with Dojo.

Oct 31

Dojo Tutorial: Using dojo/hash and dojo/router

By on October 31, 2012 10:35 am

As part of our great updates to the Dojo Tutorials for Dojo 1.8, we’ve been busy creating several new tutorials.

Using dojo/hash and dojo/router

Using dojo/hash and dojo/router In JavaScript applications, modifying the URL hash is a great way to provide bookmarkable, history-enabled page states. With dojo/hash, adding this functionality is easy. In Dojo 1.8, we added dojo/hash. Coupled with dojo/router, dojo/hash can be a powerful tool for creating robust and interactive applications.

Check out the Using dojo/hash and dojo/router tutorial for Dojo 1.8, or the Using dojo/hash tutorial for Dojo 1.7, or 1.6!

Want to see a specific Tutorial? Want to Learn More?

Is there something you’d like to learn how to do with Dojo? Always wanted to know how something in Dojo works? Leave us a message in the blog comments and we’ll see about getting a tutorial created for you. Or sign-up for an upcoming SitePen Dojo Workshop to get a fully immersive hands-on experience with Dojo.