Comments (5)
Personally I prefer to keep the order of extracted keys. The chance of related keys being grouped/close together is better.
Can you explain your use case? What does sorting the strings solve / make easier?
from ngx-translate-extract.
We prefer to group our translations by meaning and not by the order they appear in the code.
For example it would be nice if translations starting with "Product" would be grouped and translations starting with "Order" would be grouped.
Our json file will contain many translations and if all translations appear in alphabetical order it will be easier for our translators to find and navigate in the file.
Maybe it could be added as an option?
from ngx-translate-extract.
I'm using an external translation service with the pot
format, so I haven't seen the need to sort keys, but I see how it could be useful.
It should be easy enough to add a sort
method to TranslationCollection
class and an option to the CLI (defaulting to false).
from ngx-translate-extract.
Committed a pull request for this: #9
from ngx-translate-extract.
Thank you for the PR!
Merged and published new package to npm registry!
from ngx-translate-extract.
Related Issues (20)
- Array value erased when extract
- Extraneous path dependency?
- Angular 13 issue HOT 51
- Extract Parser error with Array.map & join
- Key 'constructor' is not parsed HOT 1
- Translations are not extracted from object in html template
- Not working with already interpolated strings and translateParams directive
- Dynamic string in translate instant
- Translation when using <ng-content>
- Allow translation files as inputs to prevent duplicate keys in an Angular workspace
- No updates in almost a year. Is this project dead? HOT 3
- my steps and how solve my error HOT 1
- Found 0 strings. HOT 1
- Getting Error while generating extracts- Ng Version -14.0.1 HOT 5
- [Question] Can we have html tags in translation strings? HOT 1
- Labels in html files preceded by variable are not found
- How can you sort by only adding new line at the bottom
- Is there a way to extract the default values from pipes
- Error generating with Angular 16 HOT 1
- Key in angular 17 new control flow get cleaned HOT 1
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 ngx-translate-extract.