Four Kitchens: AstroJS and Drupal
Senior Drupal Engineer
Mike has been part of the Four Kitchens crew since 2018, where he works as a senior engineer and tech lead for a variety of Drupal and WordPress projects.
January 1, 1970
There are many different options available for the organization or team that decides it is time to decouple their Drupal site. There are frameworks that are designed for static site generation (SSG) and there are others that use server-side rendering (SSR), with many that claim to do both well.
React and NextJS have been popular options for a while now, and they are well-loved here at Four Kitchens as well. Another framework that is a little different from the above is Astro, and it may be worth considering.
What is Astro?Astro is an interesting framework to work with, and it only becomes more so with time. Astro’s website makes claims of performance advantages over many other frameworks in the space. The full report can be found here.
More interesting than performance claims are some of the unique features this framework brings with it. Astro has many official integrations for other popular JS frameworks. This means, for example, that part of a page could use React, while another part could use Svelte. An even more ambitious page could use Vue, React, and AlpineJS for different components. While these examples are not a typical or recommended use case, they do illustrate that flexibility is one of the real strengths of Astro.
This flexibility doesn’t come with a steep learning curve, as Astro makes use of enough familiar pieces so that newcomers aren’t immediately overwhelmed. It is possible to write Astro components in a straightforward manner, similar to HTML, and still incorporate JavaScript XML (JSX) expressions to include data in the component’s output. There are a couple of tutorials for getting started with Astro, and they do a good job of giving the general structure of a project along with some scenarios that are unique to the framework.
(Also, Houston is an adorable mascot and I am here for it!)
Using Astro with DrupalDespite all of the integrations that can be found in the Astro toolset, there is notably one key thing that is missing: There isn’t an existing integration for Drupal! The list of content management systems (CMSs) that Astro recommends are specifically headless CMSs, which make for a more natural starting point for this setup than converting a Drupal site.
Never fear, though! Drupal may not specifically be on that list, but that doesn’t mean it isn’t something that should be considered. Astro has that incredible flexibility, after all, and that means there are more options than it seems on the surface. All that is needed is an endpoint (or several) to fetch data from Drupal, and things are looking up once again.
Using the Drupal GraphQL and GraphQL Compose modules, it is possible to quickly get data ready to expose from Drupal and into the hands of a decoupled framework like Astro. With that, it becomes possible to fetch that data within Astro and build our frontend while taking advantage of many of the features that Astro offers. This can also be done with REST API or JSON:API, but for our purposes, the consistency and structure of GraphQL can’t be beat when crafting a decoupled integration with Drupal.
Using the fetch function that is available to Astro, (and JavaScript in general), we can get data from just about anywhere into our Astro components. This blends well with the head start from the compose module, as you can take an existing Drupal site and be ready to connect to a frontend framework very quickly. This means quicker prototyping and quicker assembling of components.
Astro also supports dynamic routing out of the box, which is an essential feature when connecting to a Drupal site where routes aren’t always structured like directories. Using this wildcard type of functionality, we can more easily take an existing site — regardless of the structure of the content — and get output into Astro. With the data from the routes in hand, we can get to the fun part: building the components and taking advantage of more of the Astro’s flexibility.
Flexibility is keyFor me, Astro’s strength doesn’t solely come from the speed that it builds and renders content or the ease of building pages in a familiar JSX or Markdown pattern. Its real strength comes from the flexibility and variety of build options. While it does a great job handling some functionality on a given component or creating simple pages for a blog listing, it does even more with the ability to bring in other frameworks inside of components. Want to add a search page, but there isn’t an existing integration for Astro? If there is one for React, that works here, too! Do you have an internal team member really excited about building personalized content with Vue? Bring that in, and that component will work as well.
While the reality of the implementations may be a bit more involved than described on the tin, it is surprisingly easy and encouraged to bring in live updating components inside of Astro. This changes what would otherwise be a run-of-the-mill frontend tool into something much more interesting. Astro does shine in its own right, especially with statically generated pages and content. It just wouldn’t be doing anything especially new without bringing in other frameworks.
This is also where bringing a CMS like Drupal into a decoupled setup with Astro is intriguing. There is an opportunity for highly dynamic pages that wouldn’t work with a traditional static framework while still getting the speed and benefits of that approach. Drupal sites are typically very quick to update when content changes, which can be a sticking point for working with a decoupled architecture. How often should the frontend be rebuilt and how much can caching make up the difference? With having some parts of the site use components that can update more easily on the page, there benefits of both approaches can come through.
The post AstroJS and Drupal appeared first on Four Kitchens.
The Drop Times: Drupal is Missing a Comprehensive List of its Features!
The Drop Times: Surprise Announcements from DrupalSouth Sydney 2024!
ImageX: DrupalCon Portland 2024: Top Session Picks from Our Team
Authored by: Nadiia Nykolaichuk
“Join us this spring in the City of Roses, Portland!”
— the DrupalCon team
The best opportunity to grow your Drupal skills, plant the seeds of connection, and help the Drupal community flourish is just around the corner! This spring, the world’s biggest Drupal meetup is coming back to the City of Roses, which is one of the most famous nicknames for Portland, Oregon.
Drupal Association blog: Skills Upgrade: Drupal 7 to Drupal 10 - a community story
The Drupal Association has published this guest blog on behalf of author John Picozzi, in collaboration with Chat Hester, Stephen Cross, Nic Laflin, Mike Anello, and AmyJune Hineline.
“Never doubt that a small group of thoughtful, committed citizens can change the world; indeed, it's the only thing that ever has.” - Margaret Mead
In my mind, the above quote distills the Drupal Community down to one sentence and perfectly describes its mission. Many in the community also use “Come for the code, stay for the community” to highlight that Drupal is more than just open-source software; it’s a community of committed citizens focused on helping each other, growing skills, and developing world-changing open-source software. As many are aware, Drupal 7 will reach end-of-life (EOL) at the end of this year. Many are working to move their sites to Drupal 10, while others are looking to “Level Up” their skills to work with the latest and greatest Drupal version. This story highlights the journey of one developer and how we as a community came together to help him (and hopefully many others) achieve Drupal 10 readiness.
Our story starts with Drupal Slack and the following message from Chad Hester (chadhester).
“Hey, I have an idea that I wanted to run by you… Since I'm looking for more contracting work, getting back in to Drupal development is on my radar. I haven't done development work since Drupal 7, though. I'm out of practice since ~2015. There are lots of people who learn Drupal for the first time, but I wonder if anyone has documented their experience re-learning Drupal. Perhaps that's something that could be good as a Talking Drupal mini-series. What do you think?”
I thought it was an interesting idea and told Chad I would take it back to the team at Talking Drupal to discuss. The Talking Drupal team, Stephen Cross (stephencross), John Picozzi (johnpicozzi) & Nic Laflin (nicxvan), discussed and loved the idea. Working with Chad, they refined the show format and structure to something like a scrum meeting, where each week they reviewed what was done, what challenges were faced, and what tasks should be completed in the week to come. While brainstorming about the mini-series format they also thought of community members who could be involved.
At Talking Drupal, we strive to provide the Drupal community a platform for learning and awareness. We also include the community in creating that content as much as possible. To that end, we identified Mike Anello (ultimike) of DrupalEasy as a great choice for a mentor and AmyJune Hineline (volkswagenchick) of the Linux Foundation as a host for the series. After identifying all the folks we planned to include, Stephen started outreach, and quickly, everyone was onboard. Within three weeks of the above Slack message, we started recording our first episode. From that point, we started recording weekly and planned eight episodes.
Everyone contributed to the goals of this mini-series and added their perspective. We wanted to ensure the series would help the community move from Drupal 7 development to Drupal 10 development. However, we also wanted to go above and beyond with real open-source contributions. Mike provided that via a capstone goal of having Chad contribute an automated test to a real-life contrib project. This goal was a perfect outcome and would not only empower Chad to contribute but could empower anyone who watched the series. Overall, we have set out to bring in community members to build content for others. Allowing community members to push/pull others forward in their skill set.
Today, we are happy to share the first episodes of the Talking Drupal Mini Series: Skills Upgrade. A developer's journey from Drupal 7 to Drupal 10. Through this effort the community has come together to support its members to grow and learn. The power of the Drupal Community isn’t in the software we develop, it's in the people we empower. Those people are empowered to learn, grow, and use amazing open-source software. Indeed, I believe this group of thoughtful, committed citizens have done their little bit to change the world.
Episodes will be released over the next few weeks. Thank you, and Enjoy!
Nonprofit Drupal posts: March Drupal for Nonprofits Chat: NTC Wrap-Up and DrupalCon Planning
Join us THURSDAY, March 21 at 1pm ET / 10am PT, for our regularly scheduled call to chat about all things Drupal and nonprofits. (Convert to your local time zone.)
This month we'll be giving a recap of last week's NTC, and an update on our plans for DrupalCon Portland, including the Nonprofit Summit and the recently announced discount for nonprofit attendees!
And we'll of course also have time to discuss anything else that's on our minds at the intersection of Drupal and nonprofits. Got something specific you want to talk about? Feel free to share ahead of time in our collaborative Google doc: https://nten.org/drupal/notes!
All nonprofit Drupal devs and users, regardless of experience level, are always welcome on this call.
This free call is sponsored by NTEN.org and open to everyone.
-
Join the call: https://us02web.zoom.us/j/81817469653
-
Meeting ID: 818 1746 9653
Passcode: 551681 -
One tap mobile:
+16699006833,,81817469653# US (San Jose)
+13462487799,,81817469653# US (Houston) -
Dial by your location:
+1 669 900 6833 US (San Jose)
+1 346 248 7799 US (Houston)
+1 253 215 8782 US (Tacoma)
+1 929 205 6099 US (New York)
+1 301 715 8592 US (Washington DC)
+1 312 626 6799 US (Chicago) -
Find your local number: https://us02web.zoom.us/u/kpV1o65N
-
- Follow along on Google Docs: https://nten.org/drupal/notes
The Drop Times: The Drupal Project Update: Highlights from DrupalSouth Sydney 2024
Salsa Digital: DrupalSouth 2024 day 1 wrap-up
LN Webworks: How To Upgrade From Drupal 7 to 10: Step By Step Guide
Since its debut in 2010, Drupal 7 has provided a stable foundation for innumerable websites. But moving to a newer version—like Drupal 10—becomes crucial to guarantee security, performance, and access to the newest features as Drupal 7 approaches its end of life on January 5, 2025.
Even though this Drupal upgrade has the potential to be revolutionary, it's important to know what features you might face while upgrading from Drupal 7 to 10. This will enable you to plan appropriately and gain a clear understanding of what to anticipate.
LN Webworks: How to Drupal 7 to Drupal 10 Upgrade: Step By Step Guide
Since its debut in 2010, Drupal 7 has provided a stable foundation for innumerable websites. But moving to a newer version—like Drupal 10—becomes crucial to guarantee security, performance, and access to the newest features as Drupal 7 approaches its end of life on January 5, 2025.
Even though this Drupal upgrade has the potential to be revolutionary, it's important to know what features you might face while upgrading from Drupal 7 to 10. This will enable you to plan appropriately and gain a clear understanding of what to anticipate.
Talking Drupal: Skills Upgrade #3
Welcome back to “Skills Upgrade” a Talking Drupal mini-series following the journey of a D7 developer learning D10. This is episode 3.
Topics-
Review Chad's goals for the previous week
- DDEV performance improvements
- Install Drupal 10
- Install drupal/core-dev
- Configure and test phpcs
- Test phpstan
- settings.local.php
- Install Devel module
-
Review Chad's questions
- Rancher Desktop appears to be holding on to port 443 after I installed it. Although I changed the port to something else, do you have any suggestions to update the setup to use ports 443 and 80 instead?
- How are tools like phpcs and PHPStan used by the Drupal community for contrib? Are they a part of drupal.org's testing automation?
- Starting a new D10 website from scratch in DDEV is one thing … How would I typically work with an existing D10 website? Do I start with the community config, then overwrite the code, database, and files? Is there a better approach?
-
Tasks for the upcoming week
-
Install Drush using Composer
-
Examples module
-
routes/controllers/forms
- Review: https://www.drupal.org/docs/drupal-apis/routing-system/introductory-drupal-routes-and-controllers-example
- Go through the "Page example" module from the Examples module.
-
Check back for "docker context use rancher-desktop" stuff.
-
Create a new Git repository for your D10 site with Composer dependencies not committed to the repository.
- .gitignore stuff
- cp web/example.gitignore web/.gitignore
- Create ./.gitignore with:
-
Chad's Drupal 10 Learning Curriclum & Journal Chad's Drupal 10 Learning Notes
The Linux Foundation is offering a discount of 30% off e-learning courses, certifications and bundles with the code, all uppercase DRUPAL24 and that is good until June 5th https://training.linuxfoundation.org/certification-catalog/
HostsAmyJune Hineline - @volkswagenchick
GuestsChad Hester - chadkhester.com @chadkhest Mike Anello - DrupalEasy.com @ultimike
The Drop Times: DrupalSouth Sydney 2024 Celebrates Excellence with the Splash Awards Winners
qtatech.com blog: Drupal Meets Symfony: A Match Made for API Innovation
In the rapidly evolving landscape of web development, the union of Drupal and Symfony represents a pioneering approach towards API innovation. Enter Drupal, known for its robust content management capabilities, and Symfony, renowned for its flexibility and scalability.
Evolving Web: 9 Ways to Make the Most of the EvolveDrupal Summit
Hi there! I’m Jasmin Merchant, a Front-End Developer at Evolving Web. A few years ago I knew very little about the open web. That all changed when I started working here and was plunged into ongoing learning opportunities.
The EvolveDrupal Ottawa summit in 2023 was a big part of my learning curve. Hosted by Evolving Web, the event was a chance to gain new knowledge about development, accessibility, UX, digital strategy, and many other relevant topics.
What’s more, it was a great introduction to networking. This was my first tech summit and I had only moved to Canada one week before, so I was nervous to say the least. But EvolveDrupal was a valuable experience that really built my confidence.
I’ve shared my takeaways in this article to help others who are planning to attend EvolveDrupal (or any tech event). Use these 9 tips to attend with confidence and make the most of it!
Before the Summit 1. Create your own scheduleMy day at EvolveDrupal Ottawa started with coffee (because obviously!). I hung out in the foyer where I could chat to people as they arrived. I was looking forward to talks on Drupal, design, AI, and much more. Crucially, I had gone through the session list earlier and planned out my day.
Having your own schedule means you can pace yourself, attend the talks you're most interested in, and maximize your networking opportunities. Remember that EvolveDrupal has a wide range of sessions and many of them run in parallel, so it isn’t possible to attend all of them.
I’d recommend making space in your schedule for a bit of down time to recharge. I found this was easy to do at EvolveDrupal—the event was very well organized with little breaks between sessions, helping me to relax and go with the flow.
Evolving Web often organizes a pre-summit dinner the night before EvolveDrupal. As an introvert, I found this was a great way to ease into networking. I got to meet some really interesting, talented people and talk to them on a personal level over a nice meal. It meant that I saw some familiar faces in the crowd full of attendees the next day.
Can’t attend the pre-summit dinner? Don’t worry, you can connect digitally with organizers, speakers and participants before the summit instead. If you’ve registered for the summit, you’ll be invited to the EvolveDrupal Slack channel.
3. Build your visibilityPost on social media to tell your connections that you’ll be at EvolveDrupal. This can help you connect with more people at the event. Remember to tag Evolving Web on LinkedIn so we can help boost your post!
Email specific contacts and invite them to the summit, too. This can be a great way to grow and strengthen existing business relationships.
Want to maximize your visibility? Apply to be a speaker or sponsor. It’s a fantastic way to get in front of an audience—both in-person at the summit and also in Evolving Web’s digital communications.
“I had a blast yesterday talking at the EvolveDrupal conference in Ottawa. Thank you for giving me the opportunity. Based on the number of people in the audience that raised their phone to take pictures of the slides, I guess the content was on point!”
– Gauthier Garnier, Platform.sh (EvolveDrupal Ottawa 2023)
During the Summit 4. Make notesAt each session I attended at EvolveDrupal, I took notes about everything interesting and important that I was learning. Have a think about how you prefer to take notes—can you do it on your phone, or should you bring a tablet or notebook?
It’s best to jot down new knowledge and ideas at the event itself, before you forget. That said, some EvolveDrupal sessions are recorded and published a few weeks later, so you may have a chance to rewatch select talks.
5. Embrace a bit of discomfortWhile the pre-summit dinner put me at greater ease, I was still nervous about networking. But I learned that it’s ok to be outside of my comfort zone. As one of the speakers said: “get comfortable being uncomfortable.” Their talk was on AI, but I think the concept can be applied to a lot more!
I started by introducing myself to people I sat near during the sessions. This felt easier as there was already a clear topic to start the conversation. I met many more people at lunch and kept taking mental notes that I wrote down later. If there’s someone you want to follow up with, ask for their business card or record their name so you can add them on LinkedIn.
It’s also worth engaging with the speakers who interest you. As experts they can offer valuable information, and they’re usually more than happy to expand on their talk if you ask questions.
EvolveDrupal Ottawa finished with a networking reception, but my day didn’t end there! I attended a post-summit dinner and drinks with people who wanted to continue connecting. As it was the end of the night, everyone was relaxed and chatting easily. It was a good chance to speak again with the people I’d met that day and get to know them better. Evolving Web often arranges a post-summit dinner, so leave your evening open if you can.
After the Summit 7. Follow up with your connectionsI added most of the people I met at EvolveDrupal Ottawa on LinkedIn. It’s an easy way to stay connected because you can respond to their posts or share useful things with them. It’s also a good idea to send a personalized message to new contacts who you want to develop a deeper relationship with, such as business prospects and potential employers. Ask for a phone call or face-to-face meeting to discuss opportunities.
8. Organize and apply what you learnedWrite up your notes soon after the summit. If you leave it too long, you may forget them or find they don’t make sense any more! Also, decide how you’re going to integrate your new knowledge into your workflows and projects. Act quickly while you’re still feeling energized from the event.
“It was a treasure trove of UX wisdom… Big thanks to the amazing speakers and organizers for making this experience unforgettable. Can't wait to apply what I've learned. Count me in for the next one!”
– Milan Nayak, UX Designer (EvolveDrupal Toronto 2023)
9. Share your insights and experienceMy time at EvolveDrupal was eye-opening, so I wanted to share my experience in an article to help future participants. You can also share takeaways via an email, team meeting, or internal presentation. Finally, it’s always nice to thank the speakers on social media and tell them what you liked about their session.
I hope this article inspires you to attend EvolveDrupal with confidence and purpose. Sign up for updates to hear about upcoming events. Our next stops are in Atlanta (April 12) and Montreal (June 14)—we look forward to seeing you there!
+ more awesome articles by Evolving WebThe Drop Times: Catch Up with the Drupal Community at DrupalSouth Sydney 2024!
Specbee: Hooks or Events? Choosing the Best Approach for your Drupal Project
Acquia Developer Portal Blog: DevOps: The Gravity of the Modern Web Cosmos
Some of the illustrations in this article are created by: Martin Anderson-Clutz and Thomas Scola.
Talking Drupal: Talking Drupal #442 - Mercury Editor
Today we are talking about Mercury Editor, What it does, and how it could change your editorial life with guest Justin Toupin. We’ll also cover Webform Protected Downloads as our module of the week.
For show notes visit: www.talkingDrupal.com/442
Topics- What is Mercury Editor
- What is powering Mercury Editor
- Do you see any risk building on top of Paragraphs
- Does Mercury Editor cost anything
- Can companies hire Aten to add features
- What are some key features
- What makes Mercury Editor unique
- How stable is the content
- What happens if Paragraphs stops being supported
- How can the community help
- Mercury Editor
- Layout Paragraphs Episode
- Layout Paragraphs
- Paragraphs Library
- Sub-module of Paragraphs
- Style options
- Layout Paragraphs restrictions
Justin Toupin - atendesigngroup.com justin2pin
HostsNic Laflin - nLighteneddevelopment.com nicxvan John Picozzi - epam.com johnpicozzi Anna Mykhailova - kalamuna.com amykhailova
MOTW CorrespondentMartin Anderson-Clutz - mandclu
- Brief description:
- Have you ever wanted to have downloadable content on your website, only available to visitors who have filled out a webform? There’s a module for that.
- Module name/project name:
- Brief history
- How old: created in Sep 2010 by berliner, but the most recent releases are by james.williams of Computer Minds
- Versions available: 7.x-1.1 and 8.x-1.0-alpha2 versions available, the latter of which works with Drupal 9 and 10
- Maintainership
- Actively maintained, the latest release was a week ago
- Security coverage
- Introductory blog linked on the project page
- Number of open issues: 18 open issues, none of which are bugs against the current branch
- Usage stats:
- 804 sites
- Module features and usage
- Having thought leadership content like white papers or reports gated behind a lead capture form is a common pattern for websites, and this module is designed to make that easy to set up
- You use the module by adding a handler to your webform, similar to triggering an email send
- In the configuration for your webform protected download handler you have options for how much verification you want for the download link, whether or not the link should expire after a period of time, and so on, in addition to uploading one or more files that can be downloaded by people who submit the webform
- The module provides tokens for the download URLs, so you can easily include them in a submission confirmation message or email