Re: [xliff-omos] Modules and extensions

From
Robert van Engelen <>
Date
2017-05-23T17:11:27+00:00
ID
Thread
Re: [xliff-omos] Modules and extensions
I’m inclined to stick to _ to separate prefix from name, assuming _ are forbidden in prefixes and names by self-imposed JLIFF conventions. Underscore is at least widely supported in variable names.

Other programming languages may not accept $ in hard-coded property/variable names (i.e. console.log(x.name.b) is "hard-coded" and so is console.log(x[“name.b”]) also hard-coded, but with a period in the property name that requires quotes).

- Robert

  Dr. Robert van Engelen, CEO/CTO Genivia Inc.  voice: (850) 270 6179 ext 104  fax: (850) 270 6179  mobile: (850) 264 2676  

On May 23, 2017, at 1:03 PM, Yves Savourel <> wrote:

Regarding separator, from quick tests:

 

Dollar-sign would work, but not period, IMO:

 

var x = {"name$b": "text"};

console.log(x.name$b); à ok

 

var x = {"name.b": "text"};

console.log(x.name.b); à error

 

More tests are probably needed.

 

cheers,

-yves