question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Provide a way to name a token, and bind these names by augmenting the data array to an object.

a -> name:string {% function(d) {return d.name;} %}

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Reactions:1
  • Comments:16 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
arcaniscommented, Mar 8, 2017

A breaking change, but I think a nicer solution to this would be to use apply() instead of call() for preprocessors. So you get arguments, rather than a single array argument.

Then you can write (in ES6 at least):

a -> [\w]:+ _ [0-9]:*   {% (id, _, count) => ({ id, count }) %}

That’s still kinda possible by destructuring the parameter:

a -> [\w]:+ _ [0-9]:*   {% ([ id, _, count ]) => ({ id, count }) %}
1reaction
tjvrcommented, Feb 16, 2017

A breaking change, but I think a nicer solution to this would be to use apply() instead of call() for preprocessors. So you get arguments, rather than a single array argument.

Then you can write (in ES6 at least):

a -> [\w]:+ _ [0-9]:*   {% (id, _, count) => ({ id, count }) %}
Read more comments on GitHub >

github_iconTop Results From Across the Web

Named Tokens
In SALSA, the return value of an asynchronous message can be declared as a variable of type token. The variable is called a...
Read more >
The Practical Guide to Naming Design Tokens - UX Collective
Learn how to effectively name your design tokens in a systematic and future proof way. Understand all key concepts used today.
Read more >
What is Token Classification? - Hugging Face
Some popular token classification subtasks are Named Entity Recognition (NER) and Part-of-Speech (PoS) tagging. NER models could be trained to identify ...
Read more >
Token/Full List - MTG Wiki - Fandom
Token Name Color Type Line Banana Colorless Artifact Etherium Cell Colorless Artifact Land Mine Colorless Artifact
Read more >
Definition of Name Tokens
Name tokens are ASCII character strings composed of the letters a-z or A-Z, the digits (0-9), dashes (-) and periods (.), but nothing...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found