finnp / json-lexer

Split a JSON String into annotated tokens
15 stars 3 forks source link

implement positions #3

Open tunnckoCore opened 8 years ago

tunnckoCore commented 8 years ago

It would be good to add the positions of the tokens.

position: {
  start: {
    line: 1,
    column: 2,
    offset: 1
  },
  end: {
    line: 1,
    column: 5,
    offset: 4
  }
}