简体   繁体   中英

scala play application.conf read variables

Can I create variables in application.conf and consume by application.conf ? Basically I don't want to hard code it.

I tried dominName = "test.com" and consume with $domainName but not working.

You may need to use curly braces around the variable name: ${domainName}

You can find more example and information about HOCON on this page

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM