Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customizing the cldr json file #129

Open
blong14 opened this issue Mar 20, 2018 · 5 comments
Open

Customizing the cldr json file #129

blong14 opened this issue Mar 20, 2018 · 5 comments

Comments

@blong14
Copy link

blong14 commented Mar 20, 2018

Hello,

I am having trouble understanding how to add a customized cldr file in my loopback application. My application needs to support the Danish language which does not come out of the box with strong-globalize. I read the README found in the util directory and I think that it is saying that I need to add files directly to the node_modules/strong-globalize/cldr directory. Is that really the case? To alter the node_modules directory directly? I am new to this application but I don't think this approach is possible with how we package and deploy the application to various servers.

Thank you so much for your time.

Ben

@raymondfeng
Copy link
Member

Is Danish part of http://cldr.unicode.org/index/downloads?

@blong14
Copy link
Author

blong14 commented Mar 20, 2018

@raymondfeng yes from what I can tell. I was able to create the appropriate cldr .json file by updating the util/app.js file to uncomment "da".

@raymondfeng
Copy link
Member

I see. Maybe you can maintain your own version of cldr json file and use a npm install script to overwrite strong-gloablize/cldr?

@blong14
Copy link
Author

blong14 commented Mar 20, 2018

Ok, I can give that a try. I would also be willing to work on a pull request to add cldr path customization for strong-globalize. I'm wondering if a similar mechanism to SetRootDir could be used? Basically, provide a developer a way to specify where the cldr directory is located.

@raymondfeng
Copy link
Member

I'm not the original author of this module. But my guess is that we didn't want to make the json file too big.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants