I have a regexp in JavaScript:
new RegExp('(?:^|\\b|\\s)' + this.options.token + '([\\w.]*)$');
The problem is that this only triggers on a-e, A-E, on space etc, not “.”, “[“, “/” etc as well.
How can I extend this regexp to include these characters as well?
You just need to add them:
And so on…
This breaks down as:
Which should hopefully do what you want.