Re: [community-group] Token ID format is not ideal for consuming in hand written code (#119)

With lossy I mean this for example.

In system `one` only `a|b|-` is allowed

In system `two` `a|b|-|+|=` is allowed.

The value `ab` in system `one` can be one of these but an infinite amount of other options :

```
ab
a+b
+ab
ab+
a+=b
a=+b+==++==
```

This conversion type just drops characters that can't be converted.

You might decide to use `-` to indicate that a character was dropped.

- `a+b` -> `a-b`
- `a=b` -> `a-b`
- `a-b` -> `a-b`

Any lossy conversion is prone to collisions.
And designers would need to know all the downstream translation tools and if they have a lossy conversion.

----

Escaping characters is possible in some contexts but very awkward to type.


-- 
GitHub Notification of comment by romainmenke
Please view or discuss this issue at https://github.com/design-tokens/community-group/issues/119#issuecomment-1073358223 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Sunday, 20 March 2022 22:07:00 UTC