Skip to content

Validate angular JSON is well-formed

In charts with

angular:
      enabled: true

there is a config property that is a hunk of JSON. This JSON is served out of nginx and referenced by the application on startup, so we can build-once-deploy-anywhere. If the JSON in the yaml deployment is not well-formed, for example, has a trailing comma somewhere, it can cause issues loading the application.

If we can validate the following key is valid JSON, it should help avoid this issue.

angular:
  # Enables Angular features of chart
  enabled: true
  # Specifies the name of the file the app is requesting
  propertyFile: my-app.json
  # The app config JSON
  config: |
    {
      "some": "Field",
      "bad": "form",
    }
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information