esphome/esphome/components/json/__init__.py
Otto Winter aebad04c0b
Convert core components to async-def coroutine syntax (#1658)
Co-authored-by: Guillermo Ruffino <glm.net@gmail.com>
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2021-05-23 22:10:30 +02:00

12 lines
327 B
Python

import esphome.codegen as cg
from esphome.core import coroutine_with_priority
CODEOWNERS = ["@OttoWinter"]
json_ns = cg.esphome_ns.namespace("json")
@coroutine_with_priority(1.0)
async def to_code(config):
cg.add_library("ArduinoJson-esphomelib", "5.13.3")
cg.add_define("USE_JSON")
cg.add_global(json_ns.using)