br-state-flags is the core library providing high-fidelity, production-ready React components for all 27 Brazilian state flags. It is designed to be lightweight, dependency-free, and includes enriched geographical and demographic metadata for each state. For an interactive showcase, check the demo project.
npm install br-state-flagsimport { AC, SP } from 'br-state-flags';
const MyComponent = () => (
<div className="flex gap-4">
<AC width={120} title="Acre" />
<SP width={120} title="São Paulo" />
</div>
);The library also provides metadata for each state:
import { statesData } from 'br-state-flags';
const spData = statesData.SP;
console.log(spData.capital); // "São Paulo"
console.log(spData.population); // 45919049