jayphelps / jayphelps/string.interpolate.js
InterpolatedString's do not have complete String-like behavior
@jayphelps is already working on this.
Since Jul 5, 2013.
- Dominant language
- JavaScript
- Stars
- 2
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
Instances of `InterpolatedString` are not `Strings` and do not correctly inherit all of `Strings` behaviors, like being able to use brackets to access characters.
``` javascript
// Current, incorrect behavior
'test'.interpolate({})[0] === undefined
// Correct, future behavior
'test'.interpolate({})[0] === 't'
// This currently works though
'test'.interpolate({}).charAt(0) === 't'
// Length is incorrect as well, this is the current result
'test'.interpolate({}).length === 0
```
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.