Skip to content

Support for constants in JSON stylesheets and Swift 5.0

Latest
Compare
Choose a tag to compare
@daniel-hall daniel-hall released this 23 Jun 21:56
e621654
  • You can now define and reuse constant values inside a JSON stylesheet, thanks to @lucaslt89

    Example:

    { 
       "constants" : {
          "PrimaryBackground": "#3849DE"
        } ,
        "styles" : [
           {
              "styleName": "DefaultButton",
              "styleProperties": {
                 "titleColorForNormalState": "#D35400",
                 "backgroundColor": "$PrimaryBackground",
                 "borderColor": "#FDE3A7",
                 "cornerRadius": 6.0
          }
       ] 
    }
    
  • The Swift version is now bumped to 5.0, also thanks to @lucaslt89