With high penetration of distributed energy resources (DERs), power systems are increasingly transforming into distributed power grids, which provide grid automation, decarbonization, and decentralization of critical assets. Smart inverters are key power-electronic devices that connect renewable energy and energy storage equipment to power grids. DER includes several intelligent grid functions, such as fault ride through, grid-voltage support, and reactive-power compensation, typically with real-time remote access, data exchange, and seamless over-the-air firmware updates in a cyber-physical environment. However, cybersecurity concerns arise due to extensive information exchange among DER and multiple stakeholders (e.g., utilities, aggregators, vendors, operators, and owners). Therefore, smart inverters account for a growing attack surface for the power grid. This article reviews the cybersecurity best practices and current recommendations for smart inverters and explores emerging cyber threats for smart inverters, including malware attacks and hardware attacks. Finally, we propose a new smart inverter security and resilience framework for developing cyber-resilient smart inverters against the advanced/future threat actors. This article establishes a resilience-by-design baseline reference for smart inverter cybersecurity teams, which bridges the gap between cybersecurity and power-electronics' communities.