Sha256: 1f02d33170609740e4ec8391faf6c464469276baa3e985641eabce8c18655e8c

Contents?: true

Size: 454 Bytes

Versions: 30

Compression:

Stored size: 454 Bytes

Contents

# JSON check API

For checking the content of `.json` files.

```ruby
module ThemeCheck
  class MyCheckName < JsonCheck
    category :json,
    # A check can belong to multiple categories. Valid ones:
    categories :translation, :performance
    severity :suggestion # :error or :style

    def on_file(file)
      file # an instance of `ThemeCheck::JsonFile`
      file.content # the parsed JSON, as a Ruby object, usually a Hash
    end
  end
end
```

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
theme-check-1.15.0 docs/api/json_check.md
theme-check-1.14.0 docs/api/json_check.md
theme-check-1.13.0 docs/api/json_check.md
theme-check-1.12.1 docs/api/json_check.md
theme-check-1.12.0 docs/api/json_check.md
theme-check-1.11.0 docs/api/json_check.md
theme-check-1.10.3 docs/api/json_check.md
theme-check-1.10.2 docs/api/json_check.md
theme-check-1.10.1 docs/api/json_check.md
theme-check-1.10.0 docs/api/json_check.md
theme-check-1.9.2 docs/api/json_check.md
theme-check-1.9.1 docs/api/json_check.md
theme-check-1.9.0 docs/api/json_check.md
theme-check-1.8.0 docs/api/json_check.md
theme-check-1.7.2 docs/api/json_check.md
theme-check-1.7.1 docs/api/json_check.md
theme-check-1.7.0 docs/api/json_check.md
theme-check-1.6.2 docs/api/json_check.md
theme-check-1.6.1 docs/api/json_check.md
theme-check-1.6.0 docs/api/json_check.md