Return to site

Back to school and learning JavaScript, deeply

· Drupal,Webform,JavaScript

Even though it is has been 20+ years since I graduated from college, every September I struggle to get back to work while also feeling inspired to learn something new.

This summer I took a rest from blogging about sustainability, but I kept on coding. I felt a little guilty thinking my blog might lose its momentum, yet somehow on the “work” side, I just kept on plugging away at the Webform module’s issues queue and managed to fix a bunch of issues and make some important accessibility and UX improvements.

Coding is what I love to do; it is what drives me.

Coding is what I love to do

As I charge forward toward a stable release of Webform 8.x-5.x by Christmas, it’s time to start thinking about what’s next for the Webform module. There are a lot of people in our community thinking and talking about the future of Drupal. Drupal and most Content Management Systems (CMS) are moving towards a decoupled and headless approach.

Headless software is software capable of working on a device without a graphical user interface. Such software receives inputs and provides output through other interfaces like network or serial port and is common on servers and embedded devices.

-- https://en.wikipedia.org/wiki/Headless_software

Beginning to think about headless Webforms and Form API (FAPI)

Webform and Drupal's Form API (FAPI) has to start supporting headless Drupal and decoupled websites and applications. The Admin UI & JavaScript Modernisation is beginning to think about and experiment with, how to make Form API work with React. React will provide us with a frontend framework to build the rich user experiences and applications that our clients and users need. Choosing a frontend framework is a big decision that necessitated a considerable discussion. React's a solid choice for a frontend framework but I’m not sure it should be the foundation for an Open Source reusable form builder.

If we could decouple form elements, validation rules, and data definitions in an abstract and reusable way, any application would be able to reuse these elements or web components.

Web components

Web components are a set of web platform APIs that allow you to create new custom, reusable, encapsulated HTML tags to use in web pages and web apps. Custom components and widgets build on the Web Component standards, will work across modern browsers, and can be used with any JavaScript library or framework that works with HTML.

-- https://www.webcomponents.org/introduction

Conceptually, I was sold on the value of web components while attending John Riviello and Chris Lorenzo’s session titled "Web Components: The Future of Web Development is Here", at Drupaldelphia. They showed how Comcast is leveraging web components across all their websites.

I also watched the "Webcomponents, Polymer and HAX: decoupling authoring for Drupal and beyond" presentation by Bryan Ollendyke and Nikki Massaro Kauffman from DrupalCon Nashville. The HAX project shows the potential of web components.

There is a lot to learn about frontend frameworks and technologies

Headless Drupal has opened up our world to a variety of frontend frameworks and technologies.

A funny thing that I have to openly admit is that I have yet to code a React application or build a single web component. It took me 20 years of no longer being a student but I can now candidly say, accept, and feel no shame admitting when I don’t really know something; while knowing I can learn it. There is no way that we can know every technology. The best we can do as good software engineers is to be comfortable with continually learning new things.
 

React, Web components and all frontend works are completely new to me. The heart of all frontend frameworks is JavaScript. The real challenge we are facing with moving into the headless Content Management System world is learning JavaScript.

Learn JavaScript, Deeply

Drupal has better code and API's than WordPress but I have to give Matt Mullenweg credit for directly pushing the WordPress community to become better developers. In 2015, Matt told the WordPress community "To Learn JavaScript, Deeply." The only other time I have seen a tech leader take such a direct and game-changing stand on a technology was Steve Jobs rejecting Flash in favor of HTML5. Matt Mullenweg told the developers of the most popular CMS to learn JavaScript, deeply
 

Dries Buytaert has shared a similar call-to-action with the Drupal community:

Sharing my journey while relearning JavaScript

JavaScript and I go back a long way. My first steps into the world of programming was using JavaScript to generate an email via an HTML form that built using MS FrontPage and worked in Internet Explorer 3. My first HTML form and JavaScript is still online and it even works after 20+ years.

My first CMS, called the Inettool, was built using JScript and ASP. The code was entirely procedural and honestly, I still have not determined the best approach to creating object-oriented JavaScript.

I will keep posting about my experience with learning JavaScript, deeply. For now, I need to wrap up development of Webform 5.x.

Wrapping up Webform 5.x and looking to 6.x and beyond

For the past 2 years, I have done an introductory presentation and screencast about the Webform module and it’s time to explore some advanced topics including testing, APIs, plugins, hooks, and more…

I will be speaking about Advanced Webforms at BadCamp in 2018. Please attend my session or like me, you might want to start learning JavaScript and attend other great sessions at these conferences and many more.

All Posts
×

Almost done…

We just sent you an email. Please click the link in the email to confirm your subscription!

OKSubscriptions powered by Strikingly