Legacy Knowledge Base
Published Jul. 2, 2025

JS and CSS modifications will be applied upon redeployment of React/Angular npm based portlets

Written By

Alfonso Crisci

How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!

While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

Legacy Article

You are viewing an article from our legacy "FastTrack" publication program, made available for informational purposes. Articles in this program were published without a requirement for independent editing or verification and are provided"as is" without guarantee.

Before using any information from this article, independently verify its suitability for your situation and project.

Issue

  • While developing React or Angular based npm-portlets, you'll notice that, unless the browser's cache is cleared, JS and CSS modifications will not be applied upon redeployment. This is true also for DEV environments where include-and-override=portal-developer.properties is applied in the portal-ext.properties file.

Environment

  • Liferay DXP 7.0
  • Liferay DXP 7.1

Resolution

  • Ensure your environment is clean from previous tests and running in DEV mode by:
    - Stopping the server
    - Deleting the Liferay/osgi/state, Liferay/work, Tomcat/work and Tomcat/temp directories + the browser's cache
    - Adding in the include-and-override=portal-developer.propertiesin the portal-ext.properties file
    -Restarting the server
  • Rebuild your portlets with a clean task:
    - From the command line:  ./gradlew clean build or gradle clean build
    - In Liferay Developer Studio: The build>clean before the build>buildor build>deploy

Additional Information

Did this article resolve your issue ?

Legacy Knowledge Base