less / less/less-docs

Math random

Open
#526 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Less
Stars
680
Forks
442
PR merge metrics
No merged PRs in 30d

Description

Hello,

I have a use case where upon compiling a random generated number would be awesome.
Use case is to bypass browser's asset caching.

It would be awesome if I could replace this

background: url(../path/to/image.png?12345);

with something like this:

background: url(../path/to/image.png?random(5));

In this scenario I wouldn't have to worry if I've uploaded files to production server without manually changing version number.

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

No files, tests, or entry points are mentioned. First determine whether this request belongs in Less itself or in its documentation, then clarify the required random-value behavior and supported syntax. Done should mean the requested cache-busting use case has an agreed implementation or documented resolution.

Written by the indexing model from the issue text.

Assessment

Tech stack
css
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.