idea configured to automatically compile less

Reference: IDEA configured to automatically compile less

1. Computer installation node.jsenvironment;

directly under the window on the official website to download the installation file to download node.msi
after installation at the command line execute the following command indicates that the installation was successful

npm -v
node -v

QQ screenshot 20191021085827.png

2. Global Installationless

npm install -g less

3. Configurationidea

3.1 installation nodejsplug

Open ideasettingspluginsinstallation: nodejsplug, configured according to the following steps:

1480587751120337.png
After installation, reboot idea

3.2 Adding lessComponents

  1. Open ideasettingsLanguages & FrameworksNode.js and NPM;
  2. Click on the right side of the panel that opens +plus button to add the required lesscomponents (if not add here, use the command npm globally installed).

QQ screenshot 20191021091846.png

3.3 Installation file watchersPlug

Open ideasettingspluginsinstallation: file watchersplug set according to the following steps:

1480587731788935.png

After installation reboot idea

3.4 Configurationfile watchers

  1. Open ideasettingstoolsfile watchers;

  2. In the opening panel, click on the right plus button to add less configuration, looks like the plug will automatically configure the

QQ screenshot 20191021091922.png

After the above steps successfully, edit the file can be automatically compiled into less css file.

QQ screenshot 20191021092045.png

Guess you like

Origin www.cnblogs.com/ifme/p/11796340.html