Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

97
Views
Modified custom property given back from getPropertyValue in some cases

I found a weired problem when working with custom properties. Definition in css file:

--testprop: /test/01234;

When I access this property by calling

const style = window.getComputedStyle(window.document.body);
const testprop = style.getPropertyValue('--testprop');

the string value of testprop is set to /test/1234.

This means the characters /0 are parsed browser internally to /.

When the custom property is defined like so:

--testprop: '/test/01234';

the javascript access results in a string value of "/test/01234" (something I expect).

Used browser: Chrome Version 97.0.4692.71 (Offizieller Build) (64-Bit)

Do I miss something here? I wouldn't expect the rewriting of /0 in any circumstances.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

In fact this kind of problem is referenced in an existing bug report:

https://bugs.chromium.org/p/chromium/issues/detail?id=661854

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!