Fixes missing layout warnings when indexing items at build time.