less / less/less.js

@import files are not being watched in development mode

Open
#1,900 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

browser bug low priority
Dominant language
JavaScript
Stars
17k
Forks
3.4k
Avg merge
7h 42m
Merged PRs (30d)
26

Description

I thought pull request #995 should fix my issues, but apparently the current version I'm using of the LESS JS (less-1.6.3.min.js) is not watching over my import files and keeps adding them to the local storage. The only way to get the @import files refreshed is dumping my browser's local storage.

I'm using the following to setup development mode and watch mode:

less.env = "development"; less.watch();

An example of how the @import files are being imported in my style.less:

@import "_vars";
@import "_grid";
@import "_basics";
@import "_vars";

Summarising:

  • All the .less files are being imported correctly.
  • All the non-@import files are being refreshed after being modified.
  • All the @import are only being refreshed when dumping my browser's local storage.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with less-1.6.3.min.js using less.env = "development"; less.watch(); and the shown @import files. Trace the watch and local-storage behavior for imported files; done means modifying an imported .less file refreshes the result without clearing browser local storage.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.