Expand my Community achievements bar.

WKND tutorial npm run watch issues

Avatar

Level 1

I've been following the WKND tutorial again (https://experienceleague.adobe.com/en/docs/experience-manager-learn/getting-started-wknd-tutorial-de...)

Although it was going well, I've now run into an issue where 'npm run watch' does absolutely nothing similar to what happens in the instructor's video. I first followed the tutorial on my own project which I made from just the archetype, and when reaching the part where I'm supposed to run 'npm run watch', it ran a localhost:8080 instance instead of just building the frontend, and it ended up completely removing any and all CSS on the actual pages I wanted to work on when I ran it like the tutorial did. After debugging and searching for a while I simply gave up on that end due to not finding any answers.

 

At first I believed it to be an issue with my project, so I cloned it from the github repository provided by the tutorial, switched to the tutorial/component-basics-solution and ran 'npm run watch'. It seemed alright, seemingly running well despite a warning or two on the console, and after changing the SCSS, lo and behold, nothing was updating.

I changed the 'watch' script to be "watch": "webpack-dev-server --config ./webpack.dev.js --env writeToDisk & chokidar -c \"clientlib\" ./dist & aemsync -w ../ui.apps/src/main/content" which someone who was having a similar issue in another thread mentioned working for them but it unfortunately didn't work for me.

 

I'm using VSCode to mess with the HTL, SCSS, and run terminal related commands, and while my ui.frontend/dist folder is getting updated, with the color and extra attributes appearing whenever I update the SCSS, my ui.apps/.../clientlib-site isn't, so in order to deploy simple changes to the frontend I need to rebuild the entire project, which isn't great for small frontend changes. I've also attempted to run '-PautoInstallBundle' and it also doesn't work. It likely has to do with my environment not being fully prepared but at the same time I find it odd that I'd need to have a boatload of other things setup before working on a simple tutorial.

 

Anyhow, as suggested by the tutorial, I've installed AEM Sync by 'Yinkai15', HTL Language Support by 'Olman San Lee Montero', Maven for Java by Microsoft, and VSCode AEM Sync by 'yamato-ltd'. I haven't configured any of them because the tutorial didn't go over that.

 

I've followed step by step, done the exact same things, yet when I update my SCSS like the tutorial does, mine doesn't update, I need to run 'mvn clean install -PautoInstallSinglePackage' in order for any changes to be deployed and appear on the website.

 

I have also attempted the same fixes as "https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/wknd-tutorial-issue-no-fil..." this thread to no avail.

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

2 Replies

Avatar

Community Advisor and Adobe Champion

Hi, 

 

Follow the instructions from the archetype: ui.frontend/README.md

Go to "ui.frontend" and run "npm run start"

EstebanBustamante_0-1749515292552.png

 

Hope this helps



Esteban Bustamante

Avatar

Level 1

Hey, thanks for the reply.

 

I've attempted that and while it does actively update changes on the dev server @ localhost:8080, it opens the home page and not what I actually want to check out. The changes in AEM itself are still not being applied.

 

My current solution is to run 'npm run dev' and then use an extension to export the changes in ui.apps/.../clientlibs