Comments (3)
I agree with that sentiment and I'll try to implement this in the coming days. It shouldn't be too difficult...
I have a question though, in your example, how would you actually retrieve the string containing ${startsOn}
in the gettext
function during execution? Because normally you'd just get the string after interpolation. So instead of Starts on ${startsOn}
you'd get Starts on <value-of-startsOn>
.
from gettext-extractor.
Support for template literals is now released under v3.3.0
from gettext-extractor.
Hey Lukas,
You are correct, my suggested use case does not work as the string would indeed be impossible to retrieve. I planned to use node-gettext to retrieve strings and hoped to use template strings as node-gettext does not provide this functionality.
I'll just use lodash's template
function instead. I guess you could still support template literals for completeness' sake but other users might then try the same broken approach I suggested.
Anyway, thanks for your answer and thanks for maintaining this package!
from gettext-extractor.
Related Issues (20)
- Can not add multiline strings with JsExtractor HOT 1
- Allow #
- Allow #| comments HOT 1
- Add message does not allow null values HOT 1
- illegal operation on a directory HOT 3
- no strings found on keybase/client project HOT 1
- Add support for empty-attribute selectors HOT 1
- String templates are not parsed HOT 2
- Cannot extract context strings from identifiers HOT 1
- how can use for extract strings not translated into XREngine repo? HOT 10
- No extraction sometimes HOT 3
- Provide content options for HTML attribute extractor HOT 7
- Variable with type and without initializer causes error HOT 1
- gettext-extractor does not support private # HOT 1
- gettext-extractor fails when glob matches a directory HOT 2
- extracting comments not working in assignment HOT 3
- HtmlExctractors returns more characters than expected HOT 2
- Add async support
- Convert to ASM?
- Custom parser e.g. JSON
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gettext-extractor.