Why Node JS and NPM? | Community
Skip to main content
Level 8
June 9, 2025
Solved

Why Node JS and NPM?

  • June 9, 2025
  • 2 replies
  • 1182 views

Hi all,

 

I am installing AEM on my laptop.

 

Why will I need Node JS and NPM?

For build I use Maven. For code Eclipse.

 

Let us say I am developing only Back end AEM.

 

I appreciate all your replies.

 

Thanks,

Rama.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by EstebanBustamante

Hi

 

The simple answer is that an AEM project consists of several modules, including both Frontend and Backend components. While you're likely already familiar with the Backend, which typically uses Maven and Java, the Frontend by default uses Node.js, npm, JavaScript, and potentially any modern JS framework. It's possible to focus only on the Backend, but at a minimum, you'll still need to compile and deploy the entire application to your AEM instance at some point.

 

You can learn more about the structure of an AEM project here:

https://experienceleague.adobe.com/en/docs/experience-manager-core-components/using/developing/archetype/using#what-you-get

 

Hope this helps

 

 

2 replies

konstantyn_diachenko
Community Advisor
Community Advisor
June 9, 2025

Hi @nsvsrk ,

 

If you're working only on backend development in AEM - things like Sling Models, OSGi services, servlets, etc. - then:

Node.js and npm are not strictly required.


You can absolutely build and deploy using just Maven and develop in Eclipse or your preferred IDE.

However, Node.js and npm become important if your AEM project includes frontend development, such as:

  1. Client-side JavaScript (React, Vue, or even vanilla JS)
  2. CSS preprocessors like Sass or Less
  3. Frontend build tools (Webpack, Babel, PostCSS, etc.)
  4. The ui.frontend module (commonly generated by Adobe's official AEM Project Archetype)
  5. Integration with tools like aem-clientlib-generator (to package and deploy assets into AEM client libraries)

Most modern AEM projects include a ui.frontend module for handling client-side assets. Even if you're not actively developing frontend code, Maven will fail to build the full project if Node/npm aren't installed and the ui.frontend module is present.

 

Therefore:

  • Backend-only development? You don't need Node.js or npm, but you will need to somehow deploy frontend code on local instance. Without npm, Node.js you won't be able to do it. You just need it for one time.
  • Working on or building the full project? Yes - Node.js and npm are often required for frontend builds.

Best regards,

Kostiantyn Diachenko.

Kostiantyn Diachenko, Community Advisor, Certified Senior AEM Developer, creator of free AEM VLT Tool, maintainer of AEM Tools plugin.
nsvsrkAuthor
Level 8
June 10, 2025

Thanks for these valuable insights.

 

1. Please share the brief functionalities of npm and Node.js. Node,js is a server?

 

2. When I run Maven from command line or deploy using any IDE like Eclipse, will they use npm and Node.js internally?

From my side I am not invoking npm and Node.js directly myself, even when deploying front end code.

Thus, all these days I have been able to deploy my whole code (front end and back end) using just Maven alone.

How is it possible?

 

3. When I install Maven from command line or any IDE like Eclipse, do they install npm and Node.js on their own?

I only have to install them from my side?

 

Thanks,

RK.

nsvsrkAuthor
Level 8
June 10, 2025

Hi @estebanbustamante , @konstantyn_diachenko kindly reply.

 

Thanks,

RK.

EstebanBustamante
Community Advisor and Adobe Champion
EstebanBustamanteCommunity Advisor and Adobe ChampionAccepted solution
Community Advisor and Adobe Champion
June 10, 2025

Hi

 

The simple answer is that an AEM project consists of several modules, including both Frontend and Backend components. While you're likely already familiar with the Backend, which typically uses Maven and Java, the Frontend by default uses Node.js, npm, JavaScript, and potentially any modern JS framework. It's possible to focus only on the Backend, but at a minimum, you'll still need to compile and deploy the entire application to your AEM instance at some point.

 

You can learn more about the structure of an AEM project here:

https://experienceleague.adobe.com/en/docs/experience-manager-core-components/using/developing/archetype/using#what-you-get

 

Hope this helps

 

 

Esteban Bustamante