Giter Site home page Giter Site logo

Comments (8)

duncansmart avatar duncansmart commented on July 27, 2024

Looks like a bug in the older (IE6/7) JScript engine mode which is what WScript uses for old script compatibility. Not sure there's a way of getting WScript to run JScript engine in newer, more standards-compliant mode. Perhaps researching what the differences are between the old and new JScript engine modes will indicate what the issue is in less.js itself so we could submit a patch.

from less.js-windows.

duncansmart avatar duncansmart commented on July 27, 2024

Narrows it down http://blogs.msdn.com/b/jscript/archive/2009/04/17/versioning-language-features-in-jscript.aspx

  • Native JSON support – This would introduce a new built-in JSON object, and the following built-in methods – JSON.parse(), JSON.stringify(), Date.toJSON(), Number.toJSON(), Boolean.toJSON() and String.toJSON()
  • Support for accessor methods for enabling Document Object Model prototypes
  • Default the separator to “,” if the separator value is ‘undefined’ in Array.prototype.join
  • Return the length of the resultant array instead of ‘undefined’ for Array.prototype.unshift
  • Call toString() if precision is ‘undefined’ instead of throwing a “RangeError” for Number.prototype.toPrecision
  • Support for array subclassing
  • Support for trailing commas in object literals
  • Implemented Error.prototype.toString to provide better error messages
  • Support for index operator [] on string values

from less.js-windows.

marklagendijk avatar marklagendijk commented on July 27, 2024

In the article you mention there is a part about: "JScript Versioning in other JScript Hosts (for JScript Host Developers)". Is this something that something that is usable in WScript? If so this would solve our problem. I can't find any documentation on using this in WScript, though.

from less.js-windows.

duncansmart avatar duncansmart commented on July 27, 2024

No, don't think so. But based on that list of features worked out that the issue is "index operator [] on string values", or rather lack of it. Just submitting a patch to less.js now...

from less.js-windows.

marklagendijk avatar marklagendijk commented on July 27, 2024

Cool!

from less.js-windows.

duncansmart avatar duncansmart commented on July 27, 2024

Fixed in 622bc45

from less.js-windows.

duncansmart avatar duncansmart commented on July 27, 2024

Note: this fix was included in less.js itself by @cloudhead in less/less.js@e808472.

Pull request: less/less.js#452

from less.js-windows.

marklagendijk avatar marklagendijk commented on July 27, 2024

It is also included in the new release of less.js (1.1.5).

from less.js-windows.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.